home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 2: Applications / Linux Cubed Series 2 - Applications.iso / editors / emacs / xemacs / xemacs-1.006 / xemacs-1 / lib / xemacs-19.13 / lisp / eterm / tshell.elc < prev   
Emacs Compiled Lisp  |  1995-08-29  |  17.9 KB

open in: MacOS 8.1     |     Win98     |     DOS

view JSON data     |     view as text


This file was processed as: Emacs Compiled Lisp (other/emacsCompiledLisp).
This format is not currently supported by dexvert.

ConfidenceProgramDetectionMatch TypeSupport
1% dexvert Emacs Compiled Lisp (other/emacsCompiledLisp) magic Unsupported
1% dexvert Combustion 2 Particle Library (other/combustion2ParticleLibrary) ext Unsupported
100% file Emacs/XEmacs v19 byte-compiled Lisp data default
99% file data default
100% TrID Emacs/XEmacs byte-compiled Lisp (generic) default
100% xdgMime text/x-emacs-lisp default (weak)



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 3b 45 4c 43 13 00 00 00 | 0a 3b 3b 3b 20 63 6f 6d |;ELC....|.;;; com|
|00000010| 70 69 6c 65 64 20 62 79 | 20 63 74 68 6f 6d 70 40 |piled by| cthomp@|
|00000020| 77 69 6c 6c 6f 77 2e 63 | 73 2e 75 69 75 63 2e 65 |willow.c|s.uiuc.e|
|00000030| 64 75 20 6f 6e 20 54 75 | 65 20 41 75 67 20 32 39 |du on Tu|e Aug 29|
|00000040| 20 31 34 3a 30 30 3a 34 | 32 20 31 39 39 35 0a 3b | 14:00:4|2 1995.;|
|00000050| 3b 3b 20 66 72 6f 6d 20 | 66 69 6c 65 20 2f 78 65 |;; from |file /xe|
|00000060| 6d 61 63 73 2f 78 65 6d | 61 63 73 2d 31 39 2e 31 |macs/xem|acs-19.1|
|00000070| 33 2d 72 65 6c 65 61 73 | 65 2f 65 64 69 74 6f 72 |3-releas|e/editor|
|00000080| 2f 6c 69 73 70 2f 65 74 | 65 72 6d 2f 74 73 68 65 |/lisp/et|erm/tshe|
|00000090| 6c 6c 2e 65 6c 0a 3b 3b | 3b 20 65 6d 61 63 73 20 |ll.el.;;|; emacs |
|000000a0| 76 65 72 73 69 6f 6e 20 | 31 39 2e 31 33 20 58 45 |version |19.13 XE|
|000000b0| 6d 61 63 73 20 4c 75 63 | 69 64 2e 0a 3b 3b 3b 20 |macs Luc|id..;;; |
|000000c0| 62 79 74 65 63 6f 6d 70 | 20 76 65 72 73 69 6f 6e |bytecomp| version|
|000000d0| 20 32 2e 32 35 3b 20 31 | 2d 53 65 70 2d 39 34 2e | 2.25; 1|-Sep-94.|
|000000e0| 0a 3b 3b 3b 20 6f 70 74 | 69 6d 69 7a 61 74 69 6f |.;;; opt|imizatio|
|000000f0| 6e 20 69 73 20 6f 6e 2e | 0a 3b 3b 3b 20 74 68 69 |n is on.|.;;; thi|
|00000100| 73 20 66 69 6c 65 20 75 | 73 65 73 20 6f 70 63 6f |s file u|ses opco|
|00000110| 64 65 73 20 77 68 69 63 | 68 20 64 6f 20 6e 6f 74 |des whic|h do not|
|00000120| 20 65 78 69 73 74 20 69 | 6e 20 45 6d 61 63 73 20 | exist i|n Emacs |
|00000130| 31 38 2e 0a 0a 28 69 66 | 20 28 61 6e 64 20 28 62 |18...(if| (and (b|
|00000140| 6f 75 6e 64 70 20 27 65 | 6d 61 63 73 2d 76 65 72 |oundp 'e|macs-ver|
|00000150| 73 69 6f 6e 29 0a 09 20 | 28 6f 72 20 28 61 6e 64 |sion).. |(or (and|
|00000160| 20 28 62 6f 75 6e 64 70 | 20 27 65 70 6f 63 68 3a | (boundp| 'epoch:|
|00000170| 3a 76 65 72 73 69 6f 6e | 29 20 65 70 6f 63 68 3a |:version|) epoch:|
|00000180| 3a 76 65 72 73 69 6f 6e | 29 0a 09 20 20 20 20 20 |:version|).. |
|00000190| 28 73 74 72 69 6e 67 2d | 6c 65 73 73 70 20 65 6d |(string-|lessp em|
|000001a0| 61 63 73 2d 76 65 72 73 | 69 6f 6e 20 22 31 39 22 |acs-vers|ion "19"|
|000001b0| 29 29 29 0a 20 20 20 20 | 28 65 72 72 6f 72 20 22 |))). |(error "|
|000001c0| 54 68 69 73 20 66 69 6c | 65 20 77 61 73 20 63 6f |This fil|e was co|
|000001d0| 6d 70 69 6c 65 64 20 66 | 6f 72 20 45 6d 61 63 73 |mpiled f|or Emacs|
|000001e0| 20 31 39 2e 22 29 29 0a | 0a 28 72 65 71 75 69 72 | 19.")).|.(requir|
|000001f0| 65 20 27 74 65 72 6d 29 | 0a 28 64 65 66 76 61 72 |e 'term)|.(defvar|
|00000200| 20 74 73 68 65 6c 6c 2d | 70 72 6f 6d 70 74 2d 70 | tshell-|prompt-p|
|00000210| 61 74 74 65 72 6e 20 22 | 5e 5b 5e 23 24 25 3e 5c |attern "|^[^#$%>\|
|00000220| 6e 5d 2a 5b 23 24 25 3e | 5d 20 2a 22 20 22 5c 0a |n]*[#$%>|] *" "\.|
|00000230| 52 65 67 65 78 70 20 74 | 6f 20 6d 61 74 63 68 20 |Regexp t|o match |
|00000240| 70 72 6f 6d 70 74 73 20 | 69 6e 20 74 68 65 20 69 |prompts |in the i|
|00000250| 6e 66 65 72 69 6f 72 20 | 73 68 65 6c 6c 2e 0a 44 |nferior |shell..D|
|00000260| 65 66 61 75 6c 74 73 20 | 74 6f 20 5c 22 5e 5b 5e |efaults |to \"^[^|
|00000270| 23 24 25 3e 5c 5c 6e 5d | 2a 5b 23 24 25 3e 5d 20 |#$%>\\n]|*[#$%>] |
|00000280| 2a 5c 22 2c 20 77 68 69 | 63 68 20 77 6f 72 6b 73 |*\", whi|ch works|
|00000290| 20 70 72 65 74 74 79 20 | 77 65 6c 6c 2e 0a 54 68 | pretty |well..Th|
|000002a0| 69 73 20 76 61 72 69 61 | 62 6c 65 20 69 73 20 75 |is varia|ble is u|
|000002b0| 73 65 64 20 74 6f 20 69 | 6e 69 74 69 61 6c 69 73 |sed to i|nitialis|
|000002c0| 65 20 60 74 65 72 6d 2d | 70 72 6f 6d 70 74 2d 72 |e `term-|prompt-r|
|000002d0| 65 67 65 78 70 27 20 69 | 6e 20 74 68 65 20 0a 73 |egexp' i|n the .s|
|000002e0| 68 65 6c 6c 20 62 75 66 | 66 65 72 2e 0a 0a 54 68 |hell buf|fer...Th|
|000002f0| 65 20 70 61 74 74 65 72 | 6e 20 73 68 6f 75 6c 64 |e patter|n should|
|00000300| 20 70 72 6f 62 61 62 6c | 79 20 6e 6f 74 20 6d 61 | probabl|y not ma|
|00000310| 74 63 68 20 6d 6f 72 65 | 20 74 68 61 6e 20 6f 6e |tch more| than on|
|00000320| 65 20 6c 69 6e 65 2e 20 | 20 49 66 20 69 74 20 64 |e line. | If it d|
|00000330| 6f 65 73 2c 0a 74 73 68 | 65 6c 6c 2d 6d 6f 64 65 |oes,.tsh|ell-mode|
|00000340| 20 6d 61 79 20 62 65 63 | 6f 6d 65 20 63 6f 6e 66 | may bec|ome conf|
|00000350| 75 73 65 64 20 74 72 79 | 69 6e 67 20 74 6f 20 64 |used try|ing to d|
|00000360| 69 73 74 69 6e 67 75 69 | 73 68 20 70 72 6f 6d 70 |istingui|sh promp|
|00000370| 74 20 66 72 6f 6d 20 69 | 6e 70 75 74 0a 6f 6e 20 |t from i|nput.on |
|00000380| 6c 69 6e 65 73 20 77 68 | 69 63 68 20 64 6f 6e 27 |lines wh|ich don'|
|00000390| 74 20 73 74 61 72 74 20 | 77 69 74 68 20 61 20 70 |t start |with a p|
|000003a0| 72 6f 6d 70 74 2e 0a 0a | 54 68 69 73 20 69 73 20 |rompt...|This is |
|000003b0| 61 20 66 69 6e 65 20 74 | 68 69 6e 67 20 74 6f 20 |a fine t|hing to |
|000003c0| 73 65 74 20 69 6e 20 79 | 6f 75 72 20 60 2e 65 6d |set in y|our `.em|
|000003d0| 61 63 73 27 20 66 69 6c | 65 2e 22 29 0a 28 64 65 |acs' fil|e.").(de|
|000003e0| 66 76 61 72 20 74 73 68 | 65 6c 6c 2d 63 6f 6d 70 |fvar tsh|ell-comp|
|000003f0| 6c 65 74 69 6f 6e 2d 66 | 69 67 6e 6f 72 65 20 6e |letion-f|ignore n|
|00000400| 69 6c 20 22 5c 0a 2a 4c | 69 73 74 20 6f 66 20 73 |il "\.*L|ist of s|
|00000410| 75 66 66 69 78 65 73 20 | 74 6f 20 62 65 20 64 69 |uffixes |to be di|
|00000420| 73 72 65 67 61 72 64 65 | 64 20 64 75 72 69 6e 67 |sregarde|d during|
|00000430| 20 66 69 6c 65 2f 63 6f | 6d 6d 61 6e 64 20 63 6f | file/co|mmand co|
|00000440| 6d 70 6c 65 74 69 6f 6e | 2e 0a 54 68 69 73 20 76 |mpletion|..This v|
|00000450| 61 72 69 61 62 6c 65 20 | 69 73 20 75 73 65 64 20 |ariable |is used |
|00000460| 74 6f 20 69 6e 69 74 69 | 61 6c 69 7a 65 20 60 74 |to initi|alize `t|
|00000470| 65 72 6d 2d 63 6f 6d 70 | 6c 65 74 69 6f 6e 2d 66 |erm-comp|letion-f|
|00000480| 69 67 6e 6f 72 65 27 20 | 69 6e 20 74 68 65 20 73 |ignore' |in the s|
|00000490| 68 65 6c 6c 0a 62 75 66 | 66 65 72 2e 20 20 54 68 |hell.buf|fer. Th|
|000004a0| 65 20 64 65 66 61 75 6c | 74 20 69 73 20 6e 69 6c |e defaul|t is nil|
|000004b0| 2c 20 66 6f 72 20 63 6f | 6d 70 61 74 69 62 69 6c |, for co|mpatibil|
|000004c0| 69 74 79 20 77 69 74 68 | 20 6d 6f 73 74 20 73 68 |ity with| most sh|
|000004d0| 65 6c 6c 73 2e 0a 53 6f | 6d 65 20 70 65 6f 70 6c |ells..So|me peopl|
|000004e0| 65 20 6c 69 6b 65 20 28 | 5c 22 7e 5c 22 20 5c 22 |e like (|\"~\" \"|
|000004f0| 23 5c 22 20 5c 22 25 5c | 22 29 2e 0a 0a 54 68 69 |#\" \"%\|")...Thi|
|00000500| 73 20 69 73 20 61 20 66 | 69 6e 65 20 74 68 69 6e |s is a f|ine thin|
|00000510| 67 20 74 6f 20 73 65 74 | 20 69 6e 20 79 6f 75 72 |g to set| in your|
|00000520| 20 60 2e 65 6d 61 63 73 | 27 20 66 69 6c 65 2e 22 | `.emacs|' file."|
|00000530| 29 0a 28 64 65 66 76 61 | 72 20 74 73 68 65 6c 6c |).(defva|r tshell|
|00000540| 2d 64 65 6c 69 6d 69 74 | 65 72 2d 61 72 67 75 6d |-delimit|er-argum|
|00000550| 65 6e 74 2d 6c 69 73 74 | 20 27 28 31 32 34 20 33 |ent-list| '(124 3|
|00000560| 38 20 36 30 20 36 32 20 | 34 30 20 34 31 20 35 39 |8 60 62 |40 41 59|
|00000570| 29 20 22 5c 0a 4c 69 73 | 74 20 6f 66 20 63 68 61 |) "\.Lis|t of cha|
|00000580| 72 61 63 74 65 72 73 20 | 74 6f 20 72 65 63 6f 67 |racters |to recog|
|00000590| 6e 69 73 65 20 61 73 20 | 73 65 70 61 72 61 74 65 |nise as |separate|
|000005a0| 20 61 72 67 75 6d 65 6e | 74 73 2e 0a 54 68 69 73 | argumen|ts..This|
|000005b0| 20 76 61 72 69 61 62 6c | 65 20 69 73 20 75 73 65 | variabl|e is use|
|000005c0| 64 20 74 6f 20 69 6e 69 | 74 69 61 6c 69 7a 65 20 |d to ini|tialize |
|000005d0| 60 74 65 72 6d 2d 64 65 | 6c 69 6d 69 74 65 72 2d |`term-de|limiter-|
|000005e0| 61 72 67 75 6d 65 6e 74 | 2d 6c 69 73 74 27 20 69 |argument|-list' i|
|000005f0| 6e 20 74 68 65 0a 73 68 | 65 6c 6c 20 62 75 66 66 |n the.sh|ell buff|
|00000600| 65 72 2e 20 20 54 68 65 | 20 64 65 66 61 75 6c 74 |er. The| default|
|00000610| 20 69 73 20 28 3f 5c 5c | 7c 20 3f 26 20 3f 3c 20 | is (?\\|| ?& ?< |
|00000620| 3f 3e 20 3f 5c 5c 28 20 | 3f 5c 5c 29 20 3f 5c 5c |?> ?\\( |?\\) ?\\|
|00000630| 3b 29 2e 0a 0a 54 68 69 | 73 20 69 73 20 61 20 66 |;)...Thi|s is a f|
|00000640| 69 6e 65 20 74 68 69 6e | 67 20 74 6f 20 73 65 74 |ine thin|g to set|
|00000650| 20 69 6e 20 79 6f 75 72 | 20 60 2e 65 6d 61 63 73 | in your| `.emacs|
|00000660| 27 20 66 69 6c 65 2e 22 | 29 0a 28 64 65 66 76 61 |' file."|).(defva|
|00000670| 72 20 74 73 68 65 6c 6c | 2d 64 79 6e 61 6d 69 63 |r tshell|-dynamic|
|00000680| 2d 63 6f 6d 70 6c 65 74 | 65 2d 66 75 6e 63 74 69 |-complet|e-functi|
|00000690| 6f 6e 73 20 27 28 74 65 | 72 6d 2d 72 65 70 6c 61 |ons '(te|rm-repla|
|000006a0| 63 65 2d 62 79 2d 65 78 | 70 61 6e 64 65 64 2d 68 |ce-by-ex|panded-h|
|000006b0| 69 73 74 6f 72 79 20 74 | 73 68 65 6c 6c 2d 64 79 |istory t|shell-dy|
|000006c0| 6e 61 6d 69 63 2d 63 6f | 6d 70 6c 65 74 65 2d 65 |namic-co|mplete-e|
|000006d0| 6e 76 69 72 6f 6e 6d 65 | 6e 74 2d 76 61 72 69 61 |nvironme|nt-varia|
|000006e0| 62 6c 65 20 74 73 68 65 | 6c 6c 2d 64 79 6e 61 6d |ble tshe|ll-dynam|
|000006f0| 69 63 2d 63 6f 6d 70 6c | 65 74 65 2d 63 6f 6d 6d |ic-compl|ete-comm|
|00000700| 61 6e 64 20 74 73 68 65 | 6c 6c 2d 72 65 70 6c 61 |and tshe|ll-repla|
|00000710| 63 65 2d 62 79 2d 65 78 | 70 61 6e 64 65 64 2d 64 |ce-by-ex|panded-d|
|00000720| 69 72 65 63 74 6f 72 79 | 20 74 65 72 6d 2d 64 79 |irectory| term-dy|
|00000730| 6e 61 6d 69 63 2d 63 6f | 6d 70 6c 65 74 65 2d 66 |namic-co|mplete-f|
|00000740| 69 6c 65 6e 61 6d 65 29 | 20 22 5c 0a 4c 69 73 74 |ilename)| "\.List|
|00000750| 20 6f 66 20 66 75 6e 63 | 74 69 6f 6e 73 20 63 61 | of func|tions ca|
|00000760| 6c 6c 65 64 20 74 6f 20 | 70 65 72 66 6f 72 6d 20 |lled to |perform |
|00000770| 63 6f 6d 70 6c 65 74 69 | 6f 6e 2e 0a 54 68 69 73 |completi|on..This|
|00000780| 20 76 61 72 69 61 62 6c | 65 20 69 73 20 75 73 65 | variabl|e is use|
|00000790| 64 20 74 6f 20 69 6e 69 | 74 69 61 6c 69 73 65 20 |d to ini|tialise |
|000007a0| 60 74 65 72 6d 2d 64 79 | 6e 61 6d 69 63 2d 63 6f |`term-dy|namic-co|
|000007b0| 6d 70 6c 65 74 65 2d 66 | 75 6e 63 74 69 6f 6e 73 |mplete-f|unctions|
|000007c0| 27 20 69 6e 20 74 68 65 | 0a 73 68 65 6c 6c 20 62 |' in the|.shell b|
|000007d0| 75 66 66 65 72 2e 0a 0a | 54 68 69 73 20 69 73 20 |uffer...|This is |
|000007e0| 61 20 66 69 6e 65 20 74 | 68 69 6e 67 20 74 6f 20 |a fine t|hing to |
|000007f0| 73 65 74 20 69 6e 20 79 | 6f 75 72 20 60 2e 65 6d |set in y|our `.em|
|00000800| 61 63 73 27 20 66 69 6c | 65 2e 22 29 0a 28 64 65 |acs' fil|e.").(de|
|00000810| 66 76 61 72 20 73 68 65 | 6c 6c 2d 63 6f 6d 6d 61 |fvar she|ll-comma|
|00000820| 6e 64 2d 72 65 67 65 78 | 70 20 22 5b 5e 3b 26 7c |nd-regex|p "[^;&||
|00000830| 5c 6e 5d 2b 22 20 22 5c | 0a 2a 52 65 67 65 78 70 |\n]+" "\|.*Regexp|
|00000840| 20 74 6f 20 6d 61 74 63 | 68 20 61 20 73 69 6e 67 | to matc|h a sing|
|00000850| 6c 65 20 63 6f 6d 6d 61 | 6e 64 20 77 69 74 68 69 |le comma|nd withi|
|00000860| 6e 20 61 20 70 69 70 65 | 6c 69 6e 65 2e 0a 54 68 |n a pipe|line..Th|
|00000870| 69 73 20 69 73 20 75 73 | 65 64 20 66 6f 72 20 64 |is is us|ed for d|
|00000880| 69 72 65 63 74 6f 72 79 | 20 74 72 61 63 6b 69 6e |irectory| trackin|
|00000890| 67 20 61 6e 64 20 64 6f | 65 73 20 6e 6f 74 20 64 |g and do|es not d|
|000008a0| 6f 20 61 20 70 65 72 66 | 65 63 74 20 6a 6f 62 2e |o a perf|ect job.|
|000008b0| 22 29 0a 28 64 65 66 76 | 61 72 20 73 68 65 6c 6c |").(defv|ar shell|
|000008c0| 2d 63 6f 6d 70 6c 65 74 | 69 6f 6e 2d 65 78 65 63 |-complet|ion-exec|
|000008d0| 6f 6e 6c 79 20 74 20 22 | 5c 0a 2a 49 66 20 6e 6f |only t "|\.*If no|
|000008e0| 6e 2d 6e 69 6c 2c 20 75 | 73 65 20 65 78 65 63 75 |n-nil, u|se execu|
|000008f0| 74 61 62 6c 65 20 66 69 | 6c 65 73 20 6f 6e 6c 79 |table fi|les only|
|00000900| 20 66 6f 72 20 63 6f 6d | 70 6c 65 74 69 6f 6e 20 | for com|pletion |
|00000910| 63 61 6e 64 69 64 61 74 | 65 73 2e 0a 54 68 69 73 |candidat|es..This|
|00000920| 20 6d 69 72 72 6f 72 73 | 20 74 68 65 20 6f 70 74 | mirrors| the opt|
|00000930| 69 6f 6e 61 6c 20 62 65 | 68 61 76 69 6f 72 20 6f |ional be|havior o|
|00000940| 66 20 74 63 73 68 2e 0a | 0a 44 65 74 65 63 74 69 |f tcsh..|.Detecti|
|00000950| 6e 67 20 65 78 65 63 75 | 74 61 62 69 6c 69 74 79 |ng execu|tability|
|00000960| 20 6f 66 20 66 69 6c 65 | 73 20 6d 61 79 20 73 6c | of file|s may sl|
|00000970| 6f 77 20 63 6f 6d 6d 61 | 6e 64 20 63 6f 6d 70 6c |ow comma|nd compl|
|00000980| 65 74 69 6f 6e 20 63 6f | 6e 73 69 64 65 72 61 62 |etion co|nsiderab|
|00000990| 6c 79 2e 22 29 0a 28 64 | 65 66 76 61 72 20 73 68 |ly.").(d|efvar sh|
|000009a0| 65 6c 6c 2d 70 6f 70 64 | 2d 72 65 67 65 78 70 20 |ell-popd|-regexp |
|000009b0| 22 70 6f 70 64 22 20 22 | 5c 0a 2a 52 65 67 65 78 |"popd" "|\.*Regex|
|000009c0| 70 20 74 6f 20 6d 61 74 | 63 68 20 73 75 62 73 68 |p to mat|ch subsh|
|000009d0| 65 6c 6c 20 63 6f 6d 6d | 61 6e 64 73 20 65 71 75 |ell comm|ands equ|
|000009e0| 69 76 61 6c 65 6e 74 20 | 74 6f 20 70 6f 70 64 2e |ivalent |to popd.|
|000009f0| 22 29 0a 28 64 65 66 76 | 61 72 20 73 68 65 6c 6c |").(defv|ar shell|
|00000a00| 2d 70 75 73 68 64 2d 72 | 65 67 65 78 70 20 22 70 |-pushd-r|egexp "p|
|00000a10| 75 73 68 64 22 20 22 5c | 0a 2a 52 65 67 65 78 70 |ushd" "\|.*Regexp|
|00000a20| 20 74 6f 20 6d 61 74 63 | 68 20 73 75 62 73 68 65 | to matc|h subshe|
|00000a30| 6c 6c 20 63 6f 6d 6d 61 | 6e 64 73 20 65 71 75 69 |ll comma|nds equi|
|00000a40| 76 61 6c 65 6e 74 20 74 | 6f 20 70 75 73 68 64 2e |valent t|o pushd.|
|00000a50| 22 29 0a 28 64 65 66 76 | 61 72 20 73 68 65 6c 6c |").(defv|ar shell|
|00000a60| 2d 70 75 73 68 64 2d 74 | 6f 68 6f 6d 65 20 6e 69 |-pushd-t|ohome ni|
|00000a70| 6c 20 22 5c 0a 2a 49 66 | 20 6e 6f 6e 2d 6e 69 6c |l "\.*If| non-nil|
|00000a80| 2c 20 6d 61 6b 65 20 70 | 75 73 68 64 20 77 69 74 |, make p|ushd wit|
|00000a90| 68 20 6e 6f 20 61 72 67 | 20 62 65 68 61 76 65 20 |h no arg| behave |
|00000aa0| 61 73 20 5c 22 70 75 73 | 68 64 20 7e 5c 22 20 28 |as \"pus|hd ~\" (|
|00000ab0| 6c 69 6b 65 20 63 64 29 | 2e 0a 54 68 69 73 20 6d |like cd)|..This m|
|00000ac0| 69 72 72 6f 72 73 20 74 | 68 65 20 6f 70 74 69 6f |irrors t|he optio|
|00000ad0| 6e 61 6c 20 62 65 68 61 | 76 69 6f 72 20 6f 66 20 |nal beha|vior of |
|00000ae0| 74 63 73 68 2e 22 29 0a | 28 64 65 66 76 61 72 20 |tcsh.").|(defvar |
|00000af0| 73 68 65 6c 6c 2d 70 75 | 73 68 64 2d 64 65 78 74 |shell-pu|shd-dext|
|00000b00| 72 61 63 74 20 6e 69 6c | 20 22 5c 0a 2a 49 66 20 |ract nil| "\.*If |
|00000b10| 6e 6f 6e 2d 6e 69 6c 2c | 20 6d 61 6b 65 20 5c 22 |non-nil,| make \"|
|00000b20| 70 75 73 68 64 20 2b 6e | 5c 22 20 70 6f 70 20 74 |pushd +n|\" pop t|
|00000b30| 68 65 20 6e 74 68 20 64 | 69 72 20 74 6f 20 74 68 |he nth d|ir to th|
|00000b40| 65 20 73 74 61 63 6b 20 | 74 6f 70 2e 0a 54 68 69 |e stack |top..Thi|
|00000b50| 73 20 6d 69 72 72 6f 72 | 73 20 74 68 65 20 6f 70 |s mirror|s the op|
|00000b60| 74 69 6f 6e 61 6c 20 62 | 65 68 61 76 69 6f 72 20 |tional b|ehavior |
|00000b70| 6f 66 20 74 63 73 68 2e | 22 29 0a 28 64 65 66 76 |of tcsh.|").(defv|
|00000b80| 61 72 20 73 68 65 6c 6c | 2d 70 75 73 68 64 2d 64 |ar shell|-pushd-d|
|00000b90| 75 6e 69 71 75 65 20 6e | 69 6c 20 22 5c 0a 2a 49 |unique n|il "\.*I|
|00000ba0| 66 20 6e 6f 6e 2d 6e 69 | 6c 2c 20 6d 61 6b 65 20 |f non-ni|l, make |
|00000bb0| 70 75 73 68 64 20 6f 6e | 6c 79 20 61 64 64 20 75 |pushd on|ly add u|
|00000bc0| 6e 69 71 75 65 20 64 69 | 72 65 63 74 6f 72 69 65 |nique di|rectorie|
|00000bd0| 73 20 74 6f 20 74 68 65 | 20 73 74 61 63 6b 2e 0a |s to the| stack..|
|00000be0| 54 68 69 73 20 6d 69 72 | 72 6f 72 73 20 74 68 65 |This mir|rors the|
|00000bf0| 20 6f 70 74 69 6f 6e 61 | 6c 20 62 65 68 61 76 69 | optiona|l behavi|
|00000c00| 6f 72 20 6f 66 20 74 63 | 73 68 2e 22 29 0a 28 64 |or of tc|sh.").(d|
|00000c10| 65 66 76 61 72 20 73 68 | 65 6c 6c 2d 63 64 2d 72 |efvar sh|ell-cd-r|
|00000c20| 65 67 65 78 70 20 22 63 | 64 22 20 22 5c 0a 2a 52 |egexp "c|d" "\.*R|
|00000c30| 65 67 65 78 70 20 74 6f | 20 6d 61 74 63 68 20 73 |egexp to| match s|
|00000c40| 75 62 73 68 65 6c 6c 20 | 63 6f 6d 6d 61 6e 64 73 |ubshell |commands|
|00000c50| 20 65 71 75 69 76 61 6c | 65 6e 74 20 74 6f 20 63 | equival|ent to c|
|00000c60| 64 2e 22 29 0a 28 64 65 | 66 76 61 72 20 65 78 70 |d.").(de|fvar exp|
|00000c70| 6c 69 63 69 74 2d 63 73 | 68 2d 61 72 67 73 20 28 |licit-cs|h-args (|
|00000c80| 62 79 74 65 2d 63 6f 64 | 65 20 22 08 c1 3d ab 82 |byte-cod|e "..=..|
|00000c90| c2 87 c3 87 22 20 5b 73 | 79 73 74 65 6d 2d 74 79 |...." [s|ystem-ty|
|00000ca0| 70 65 20 68 70 75 78 20 | 28 22 2d 69 22 20 22 2d |pe hpux |("-i" "-|
|00000cb0| 54 22 29 20 28 22 2d 69 | 22 29 5d 20 32 29 20 22 |T") ("-i|")] 2) "|
|00000cc0| 5c 0a 2a 41 72 67 73 20 | 70 61 73 73 65 64 20 74 |\.*Args |passed t|
|00000cd0| 6f 20 69 6e 66 65 72 69 | 6f 72 20 73 68 65 6c 6c |o inferi|or shell|
|00000ce0| 20 62 79 20 4d 2d 78 20 | 74 73 68 65 6c 6c 2c 20 | by M-x |tshell, |
|00000cf0| 69 66 20 74 68 65 20 73 | 68 65 6c 6c 20 69 73 20 |if the s|hell is |
|00000d00| 63 73 68 2e 0a 56 61 6c | 75 65 20 69 73 20 61 20 |csh..Val|ue is a |
|00000d10| 6c 69 73 74 20 6f 66 20 | 73 74 72 69 6e 67 73 2c |list of |strings,|
|00000d20| 20 77 68 69 63 68 20 6d | 61 79 20 62 65 20 6e 69 | which m|ay be ni|
|00000d30| 6c 2e 22 29 0a 28 64 65 | 66 76 61 72 20 74 73 68 |l.").(de|fvar tsh|
|00000d40| 65 6c 6c 2d 69 6e 70 75 | 74 2d 61 75 74 6f 65 78 |ell-inpu|t-autoex|
|00000d50| 70 61 6e 64 20 27 68 69 | 73 74 6f 72 79 20 22 5c |pand 'hi|story "\|
|00000d60| 0a 2a 49 66 20 6e 6f 6e | 2d 6e 69 6c 2c 20 65 78 |.*If non|-nil, ex|
|00000d70| 70 61 6e 64 20 69 6e 70 | 75 74 20 63 6f 6d 6d 61 |pand inp|ut comma|
|00000d80| 6e 64 20 68 69 73 74 6f | 72 79 20 72 65 66 65 72 |nd histo|ry refer|
|00000d90| 65 6e 63 65 73 20 6f 6e | 20 63 6f 6d 70 6c 65 74 |ences on| complet|
|00000da0| 69 6f 6e 2e 0a 54 68 69 | 73 20 6d 69 72 72 6f 72 |ion..Thi|s mirror|
|00000db0| 73 20 74 68 65 20 6f 70 | 74 69 6f 6e 61 6c 20 62 |s the op|tional b|
|00000dc0| 65 68 61 76 69 6f 72 20 | 6f 66 20 74 63 73 68 20 |ehavior |of tcsh |
|00000dd0| 28 69 74 73 20 61 75 74 | 6f 65 78 70 61 6e 64 20 |(its aut|oexpand |
|00000de0| 61 6e 64 20 68 69 73 74 | 6c 69 74 29 2e 0a 0a 49 |and hist|lit)...I|
|00000df0| 66 20 74 68 65 20 76 61 | 6c 75 65 20 69 73 20 60 |f the va|lue is `|
|00000e00| 69 6e 70 75 74 27 2c 20 | 74 68 65 6e 20 74 68 65 |input', |then the|
|00000e10| 20 65 78 70 61 6e 73 69 | 6f 6e 20 69 73 20 73 65 | expansi|on is se|
|00000e20| 65 6e 20 6f 6e 20 69 6e | 70 75 74 2e 0a 49 66 20 |en on in|put..If |
|00000e30| 74 68 65 20 76 61 6c 75 | 65 20 69 73 20 60 68 69 |the valu|e is `hi|
|00000e40| 73 74 6f 72 79 27 2c 20 | 74 68 65 6e 20 74 68 65 |story', |then the|
|00000e50| 20 65 78 70 61 6e 73 69 | 6f 6e 20 69 73 20 6f 6e | expansi|on is on|
|00000e60| 6c 79 20 77 68 65 6e 20 | 69 6e 73 65 72 74 69 6e |ly when |insertin|
|00000e70| 67 0a 69 6e 74 6f 20 74 | 68 65 20 62 75 66 66 65 |g.into t|he buffe|
|00000e80| 72 27 73 20 69 6e 70 75 | 74 20 72 69 6e 67 2e 20 |r's inpu|t ring. |
|00000e90| 20 53 65 65 20 61 6c 73 | 6f 20 60 74 65 72 6d 2d | See als|o `term-|
|00000ea0| 6d 61 67 69 63 2d 73 70 | 61 63 65 27 20 61 6e 64 |magic-sp|ace' and|
|00000eb0| 0a 60 74 65 72 6d 2d 64 | 79 6e 61 6d 69 63 2d 63 |.`term-d|ynamic-c|
|00000ec0| 6f 6d 70 6c 65 74 65 27 | 2e 0a 0a 54 68 69 73 20 |omplete'|...This |
|00000ed0| 76 61 72 69 61 62 6c 65 | 20 73 75 70 70 6c 69 65 |variable| supplie|
|00000ee0| 73 20 61 20 64 65 66 61 | 75 6c 74 20 66 6f 72 20 |s a defa|ult for |
|00000ef0| 60 74 65 72 6d 2d 69 6e | 70 75 74 2d 61 75 74 6f |`term-in|put-auto|
|00000f00| 65 78 70 61 6e 64 27 2c | 0a 66 6f 72 20 54 73 68 |expand',|.for Tsh|
|00000f10| 65 6c 6c 20 6d 6f 64 65 | 20 6f 6e 6c 79 2e 22 29 |ell mode| only.")|
|00000f20| 0a 28 64 65 66 76 61 72 | 20 74 73 68 65 6c 6c 2d |.(defvar| tshell-|
|00000f30| 64 69 72 73 74 61 63 6b | 20 6e 69 6c 20 22 5c 0a |dirstack| nil "\.|
|00000f40| 4c 69 73 74 20 6f 66 20 | 64 69 72 65 63 74 6f 72 |List of |director|
|00000f50| 69 65 73 20 73 61 76 65 | 64 20 62 79 20 70 75 73 |ies save|d by pus|
|00000f60| 68 64 20 69 6e 20 74 68 | 69 73 20 62 75 66 66 65 |hd in th|is buffe|
|00000f70| 72 27 73 20 73 68 65 6c | 6c 2e 0a 54 68 75 73 2c |r's shel|l..Thus,|
|00000f80| 20 74 68 69 73 20 64 6f | 65 73 20 6e 6f 74 20 69 | this do|es not i|
|00000f90| 6e 63 6c 75 64 65 20 74 | 68 65 20 73 68 65 6c 6c |nclude t|he shell|
|00000fa0| 27 73 20 63 75 72 72 65 | 6e 74 20 64 69 72 65 63 |'s curre|nt direc|
|00000fb0| 74 6f 72 79 2e 22 29 0a | 28 64 65 66 76 61 72 20 |tory.").|(defvar |
|00000fc0| 74 73 68 65 6c 6c 2d 64 | 69 72 74 72 61 63 6b 70 |tshell-d|irtrackp|
|00000fd0| 20 74 20 22 5c 0a 4e 6f | 6e 2d 6e 69 6c 20 69 6e | t "\.No|n-nil in|
|00000fe0| 20 61 20 73 68 65 6c 6c | 20 62 75 66 66 65 72 20 | a shell| buffer |
|00000ff0| 6d 65 61 6e 73 20 64 69 | 72 65 63 74 6f 72 79 20 |means di|rectory |
|00001000| 74 72 61 63 6b 69 6e 67 | 20 69 73 20 65 6e 61 62 |tracking| is enab|
|00001010| 6c 65 64 2e 22 29 0a 28 | 64 65 66 76 61 72 20 74 |led.").(|defvar t|
|00001020| 73 68 65 6c 6c 2d 6c 61 | 73 74 2d 64 69 72 20 6e |shell-la|st-dir n|
|00001030| 69 6c 20 22 5c 0a 4b 65 | 65 70 20 74 72 61 63 6b |il "\.Ke|ep track|
|00001040| 20 6f 66 20 6c 61 73 74 | 20 64 69 72 65 63 74 6f | of last| directo|
|00001050| 72 79 20 66 6f 72 20 6b | 73 68 20 60 63 64 20 2d |ry for k|sh `cd -|
|00001060| 27 20 63 6f 6d 6d 61 6e | 64 2e 22 29 0a 28 64 65 |' comman|d.").(de|
|00001070| 66 76 61 72 20 74 73 68 | 65 6c 6c 2d 64 69 72 73 |fvar tsh|ell-dirs|
|00001080| 74 61 63 6b 2d 71 75 65 | 72 79 20 6e 69 6c 20 22 |tack-que|ry nil "|
|00001090| 5c 0a 43 6f 6d 6d 61 6e | 64 20 75 73 65 64 20 62 |\.Comman|d used b|
|000010a0| 79 20 60 74 73 68 65 6c | 6c 2d 72 65 73 79 6e 63 |y `tshel|l-resync|
|000010b0| 2d 64 69 72 27 20 74 6f | 20 71 75 65 72 79 20 74 |-dir' to| query t|
|000010c0| 68 65 20 73 68 65 6c 6c | 2e 22 29 0a 28 62 79 74 |he shell|.").(byt|
|000010d0| 65 2d 63 6f 64 65 20 22 | c0 c1 21 ac 82 c2 11 09 |e-code "|..!.....|
|000010e0| ac b0 c3 0c 21 11 c5 09 | c6 c7 23 88 c5 09 c8 c9 |....!...|..#.....|
|000010f0| 23 88 c5 09 ca cb 23 88 | c5 09 cc cd 23 88 ce cf |#.....#.|....#...|
|00001100| 09 d0 5c 22 d1 d2 d3 24 | 88 ce cf 09 d4 5c 22 d5 |..\"...$|.....\".|
|00001110| d6 d7 24 88 c2 87 22 20 | 5b 62 6f 75 6e 64 70 20 |..$..." |[boundp |
|00001120| 74 73 68 65 6c 6c 2d 6d | 6f 64 65 2d 6d 61 70 20 |tshell-m|ode-map |
|00001130| 6e 69 6c 20 63 6f 70 79 | 2d 6b 65 79 6d 61 70 20 |nil copy|-keymap |
|00001140| 74 65 72 6d 2d 6d 6f 64 | 65 2d 6d 61 70 20 64 65 |term-mod|e-map de|
|00001150| 66 69 6e 65 2d 6b 65 79 | 20 22 03 06 22 20 74 73 |fine-key| ".." ts|
|00001160| 68 65 6c 6c 2d 66 6f 72 | 77 61 72 64 2d 63 6f 6d |hell-for|ward-com|
|00001170| 6d 61 6e 64 20 22 03 02 | 22 20 74 73 68 65 6c 6c |mand "..|" tshell|
|00001180| 2d 62 61 63 6b 77 61 72 | 64 2d 63 6f 6d 6d 61 6e |-backwar|d-comman|
|00001190| 64 20 22 09 22 20 74 65 | 72 6d 2d 64 79 6e 61 6d |d "." te|rm-dynam|
|000011a0| 69 63 2d 63 6f 6d 70 6c | 65 74 65 20 22 bf 22 20 |ic-compl|ete "." |
|000011b0| 74 65 72 6d 2d 64 79 6e | 61 6d 69 63 2d 6c 69 73 |term-dyn|amic-lis|
|000011c0| 74 2d 66 69 6c 65 6e 61 | 6d 65 2d 63 6f 6d 70 6c |t-filena|me-compl|
|000011d0| 65 74 69 6f 6e 73 20 64 | 65 66 69 6e 65 2d 6b 65 |etions d|efine-ke|
|000011e0| 79 2d 61 66 74 65 72 20 | 6c 6f 6f 6b 75 70 2d 6b |y-after |lookup-k|
|000011f0| 65 79 20 5b 6d 65 6e 75 | 2d 62 61 72 20 63 6f 6d |ey [menu|-bar com|
|00001200| 70 6c 65 74 69 6f 6e 5d | 20 5b 63 6f 6d 70 6c 65 |pletion]| [comple|
|00001210| 74 65 2d 65 6e 76 2d 76 | 61 72 69 61 62 6c 65 5d |te-env-v|ariable]|
|00001220| 20 28 22 43 6f 6d 70 6c | 65 74 65 20 45 6e 76 2e | ("Compl|ete Env.|
|00001230| 20 56 61 72 69 61 62 6c | 65 20 4e 61 6d 65 22 20 | Variabl|e Name" |
|00001240| 2e 20 74 73 68 65 6c 6c | 2d 64 79 6e 61 6d 69 63 |. tshell|-dynamic|
|00001250| 2d 63 6f 6d 70 6c 65 74 | 65 2d 65 6e 76 69 72 6f |-complet|e-enviro|
|00001260| 6e 6d 65 6e 74 2d 76 61 | 72 69 61 62 6c 65 29 20 |nment-va|riable) |
|00001270| 63 6f 6d 70 6c 65 74 65 | 2d 66 69 6c 65 20 5b 6d |complete|-file [m|
|00001280| 65 6e 75 2d 62 61 72 20 | 63 6f 6d 70 6c 65 74 69 |enu-bar |completi|
|00001290| 6f 6e 5d 20 5b 65 78 70 | 61 6e 64 2d 64 69 72 65 |on] [exp|and-dire|
|000012a0| 63 74 6f 72 79 5d 20 28 | 22 45 78 70 61 6e 64 20 |ctory] (|"Expand |
|000012b0| 44 69 72 65 63 74 6f 72 | 79 20 52 65 66 65 72 65 |Director|y Refere|
|000012c0| 6e 63 65 22 20 2e 20 74 | 73 68 65 6c 6c 2d 72 65 |nce" . t|shell-re|
|000012d0| 70 6c 61 63 65 2d 62 79 | 2d 65 78 70 61 6e 64 65 |place-by|-expande|
|000012e0| 64 2d 64 69 72 65 63 74 | 6f 72 79 29 20 63 6f 6d |d-direct|ory) com|
|000012f0| 70 6c 65 74 65 2d 65 78 | 70 61 6e 64 5d 20 35 29 |plete-ex|pand] 5)|
|00001300| 0a 28 64 65 66 76 61 72 | 20 74 73 68 65 6c 6c 2d |.(defvar| tshell-|
|00001310| 6d 6f 64 65 2d 68 6f 6f | 6b 20 6e 69 6c 20 22 5c |mode-hoo|k nil "\|
|00001320| 0a 2a 48 6f 6f 6b 20 66 | 6f 72 20 63 75 73 74 6f |.*Hook f|or custo|
|00001330| 6d 69 73 69 6e 67 20 54 | 73 68 65 6c 6c 20 6d 6f |mising T|shell mo|
|00001340| 64 65 2e 22 29 0a 28 66 | 73 65 74 20 27 74 73 68 |de.").(f|set 'tsh|
|00001350| 65 6c 6c 2d 6d 6f 64 65 | 20 23 5b 6e 69 6c 20 22 |ell-mode| #[nil "|
|00001360| c0 20 88 c1 12 c3 14 c5 | 0e 06 21 88 0e 07 16 08 |. ......|..!.....|
|00001370| 0e 09 16 5c 6e 0e 0b 16 | 0c 0e 0d 16 0e cf d0 21 |...\n...|.......!|
|00001380| 88 0e 08 16 10 cf d1 21 | 88 d2 16 11 d2 16 13 cf |.......!|........|
|00001390| d4 21 88 d5 16 14 d6 d7 | d8 5c 22 88 0e 19 16 1a |.!......|.\".....|
|000013a0| db dc dd 70 21 21 40 21 | 1e 1e df e0 21 ae 93 0e |...p!!@!|....!...|
|000013b0| 1e e1 98 ab 83 e2 aa 8a | 0e 1e e3 98 ab 83 e4 aa |........|........|
|000013c0| 81 e5 89 16 26 e7 9a ab | 83 d2 16 26 e8 e9 0e 1e |....&...|...&....|
|000013d0| 5c 22 ab 83 ea aa 81 eb | 16 2c 29 ed ee 21 88 ef |\"......|.,)..!..|
|000013e0| d5 21 87 22 20 5b 74 65 | 72 6d 2d 6d 6f 64 65 20 |.!." [te|rm-mode |
|000013f0| 74 73 68 65 6c 6c 2d 6d | 6f 64 65 20 6d 61 6a 6f |tshell-m|ode majo|
|00001400| 72 2d 6d 6f 64 65 20 22 | 53 68 65 6c 6c 22 20 6d |r-mode "|Shell" m|
|00001410| 6f 64 65 2d 6e 61 6d 65 | 20 75 73 65 2d 6c 6f 63 |ode-name| use-loc|
|00001420| 61 6c 2d 6d 61 70 20 74 | 73 68 65 6c 6c 2d 6d 6f |al-map t|shell-mo|
|00001430| 64 65 2d 6d 61 70 20 74 | 73 68 65 6c 6c 2d 70 72 |de-map t|shell-pr|
|00001440| 6f 6d 70 74 2d 70 61 74 | 74 65 72 6e 20 74 65 72 |ompt-pat|tern ter|
|00001450| 6d 2d 70 72 6f 6d 70 74 | 2d 72 65 67 65 78 70 20 |m-prompt|-regexp |
|00001460| 74 73 68 65 6c 6c 2d 63 | 6f 6d 70 6c 65 74 69 6f |tshell-c|ompletio|
|00001470| 6e 2d 66 69 67 6e 6f 72 | 65 20 74 65 72 6d 2d 63 |n-fignor|e term-c|
|00001480| 6f 6d 70 6c 65 74 69 6f | 6e 2d 66 69 67 6e 6f 72 |ompletio|n-fignor|
|00001490| 65 20 74 73 68 65 6c 6c | 2d 64 65 6c 69 6d 69 74 |e tshell|-delimit|
|000014a0| 65 72 2d 61 72 67 75 6d | 65 6e 74 2d 6c 69 73 74 |er-argum|ent-list|
|000014b0| 20 74 65 72 6d 2d 64 65 | 6c 69 6d 69 74 65 72 2d | term-de|limiter-|
|000014c0| 61 72 67 75 6d 65 6e 74 | 2d 6c 69 73 74 20 74 73 |argument|-list ts|
|000014d0| 68 65 6c 6c 2d 64 79 6e | 61 6d 69 63 2d 63 6f 6d |hell-dyn|amic-com|
|000014e0| 70 6c 65 74 65 2d 66 75 | 6e 63 74 69 6f 6e 73 20 |plete-fu|nctions |
|000014f0| 74 65 72 6d 2d 64 79 6e | 61 6d 69 63 2d 63 6f 6d |term-dyn|amic-com|
|00001500| 70 6c 65 74 65 2d 66 75 | 6e 63 74 69 6f 6e 73 20 |plete-fu|nctions |
|00001510| 6d 61 6b 65 2d 6c 6f 63 | 61 6c 2d 76 61 72 69 61 |make-loc|al-varia|
|00001520| 62 6c 65 20 70 61 72 61 | 67 72 61 70 68 2d 73 74 |ble para|graph-st|
|00001530| 61 72 74 20 74 73 68 65 | 6c 6c 2d 64 69 72 73 74 |art tshe|ll-dirst|
|00001540| 61 63 6b 20 6e 69 6c 20 | 74 73 68 65 6c 6c 2d 6c |ack nil |tshell-l|
|00001550| 61 73 74 2d 64 69 72 20 | 74 73 68 65 6c 6c 2d 64 |ast-dir |tshell-d|
|00001560| 69 72 74 72 61 63 6b 70 | 20 74 20 61 64 64 2d 68 |irtrackp| t add-h|
|00001570| 6f 6f 6b 20 74 65 72 6d | 2d 69 6e 70 75 74 2d 66 |ook term|-input-f|
|00001580| 69 6c 74 65 72 2d 66 75 | 6e 63 74 69 6f 6e 73 20 |ilter-fu|nctions |
|00001590| 74 73 68 65 6c 6c 2d 64 | 69 72 65 63 74 6f 72 79 |tshell-d|irectory|
|000015a0| 2d 74 72 61 63 6b 65 72 | 20 74 73 68 65 6c 6c 2d |-tracker| tshell-|
|000015b0| 69 6e 70 75 74 2d 61 75 | 74 6f 65 78 70 61 6e 64 |input-au|toexpand|
|000015c0| 20 74 65 72 6d 2d 69 6e | 70 75 74 2d 61 75 74 6f | term-in|put-auto|
|000015d0| 65 78 70 61 6e 64 20 66 | 69 6c 65 2d 6e 61 6d 65 |expand f|ile-name|
|000015e0| 2d 6e 6f 6e 64 69 72 65 | 63 74 6f 72 79 20 70 72 |-nondire|ctory pr|
|000015f0| 6f 63 65 73 73 2d 63 6f | 6d 6d 61 6e 64 20 67 65 |ocess-co|mmand ge|
|00001600| 74 2d 62 75 66 66 65 72 | 2d 70 72 6f 63 65 73 73 |t-buffer|-process|
|00001610| 20 73 68 65 6c 6c 20 67 | 65 74 65 6e 76 20 22 48 | shell g|etenv "H|
|00001620| 49 53 54 46 49 4c 45 22 | 20 22 62 61 73 68 22 20 |ISTFILE"| "bash" |
|00001630| 22 7e 2f 2e 62 61 73 68 | 5f 68 69 73 74 6f 72 79 |"~/.bash|_history|
|00001640| 22 20 22 6b 73 68 22 20 | 22 7e 2f 2e 73 68 5f 68 |" "ksh" |"~/.sh_h|
|00001650| 69 73 74 6f 72 79 22 20 | 22 7e 2f 2e 68 69 73 74 |istory" |"~/.hist|
|00001660| 6f 72 79 22 20 74 65 72 | 6d 2d 69 6e 70 75 74 2d |ory" ter|m-input-|
|00001670| 72 69 6e 67 2d 66 69 6c | 65 2d 6e 61 6d 65 20 22 |ring-fil|e-name "|
|00001680| 2f 64 65 76 2f 6e 75 6c | 6c 22 20 73 74 72 69 6e |/dev/nul|l" strin|
|00001690| 67 2d 6d 61 74 63 68 20 | 22 5e 6b 3f 73 68 24 22 |g-match |"^k?sh$"|
|000016a0| 20 22 70 77 64 22 20 22 | 64 69 72 73 22 20 74 73 | "pwd" "|dirs" ts|
|000016b0| 68 65 6c 6c 2d 64 69 72 | 73 74 61 63 6b 2d 71 75 |hell-dir|stack-qu|
|000016c0| 65 72 79 20 72 75 6e 2d | 68 6f 6f 6b 73 20 74 73 |ery run-|hooks ts|
|000016d0| 68 65 6c 6c 2d 6d 6f 64 | 65 2d 68 6f 6f 6b 20 74 |hell-mod|e-hook t|
|000016e0| 65 72 6d 2d 72 65 61 64 | 2d 69 6e 70 75 74 2d 72 |erm-read|-input-r|
|000016f0| 69 6e 67 5d 20 35 20 22 | 5c 0a 4d 61 6a 6f 72 20 |ing] 5 "|\.Major |
|00001700| 6d 6f 64 65 20 66 6f 72 | 20 69 6e 74 65 72 61 63 |mode for| interac|
|00001710| 74 69 6e 67 20 77 69 74 | 68 20 61 6e 20 69 6e 66 |ting wit|h an inf|
|00001720| 65 72 69 6f 72 20 73 68 | 65 6c 6c 2e 0a 52 65 74 |erior sh|ell..Ret|
|00001730| 75 72 6e 20 61 66 74 65 | 72 20 74 68 65 20 65 6e |urn afte|r the en|
|00001740| 64 20 6f 66 20 74 68 65 | 20 70 72 6f 63 65 73 73 |d of the| process|
|00001750| 27 20 6f 75 74 70 75 74 | 20 73 65 6e 64 73 20 74 |' output| sends t|
|00001760| 68 65 20 74 65 78 74 20 | 66 72 6f 6d 20 74 68 65 |he text |from the|
|00001770| 20 0a 20 20 20 20 65 6e | 64 20 6f 66 20 70 72 6f | . en|d of pro|
|00001780| 63 65 73 73 20 74 6f 20 | 74 68 65 20 65 6e 64 20 |cess to |the end |
|00001790| 6f 66 20 74 68 65 20 63 | 75 72 72 65 6e 74 20 6c |of the c|urrent l|
|000017a0| 69 6e 65 2e 0a 52 65 74 | 75 72 6e 20 62 65 66 6f |ine..Ret|urn befo|
|000017b0| 72 65 20 65 6e 64 20 6f | 66 20 70 72 6f 63 65 73 |re end o|f proces|
|000017c0| 73 20 6f 75 74 70 75 74 | 20 63 6f 70 69 65 73 20 |s output| copies |
|000017d0| 74 68 65 20 63 75 72 72 | 65 6e 74 20 6c 69 6e 65 |the curr|ent line|
|000017e0| 20 28 65 78 63 65 70 74 | 0a 20 20 20 20 66 6f 72 | (except|. for|
|000017f0| 20 74 68 65 20 70 72 6f | 6d 70 74 29 20 74 6f 20 | the pro|mpt) to |
|00001800| 74 68 65 20 65 6e 64 20 | 6f 66 20 74 68 65 20 62 |the end |of the b|
|00001810| 75 66 66 65 72 20 61 6e | 64 20 73 65 6e 64 73 20 |uffer an|d sends |
|00001820| 69 74 2e 0a 4d 2d 78 20 | 74 65 72 6d 2d 73 65 6e |it..M-x |term-sen|
|00001830| 64 2d 69 6e 76 69 73 69 | 62 6c 65 20 72 65 61 64 |d-invisi|ble read|
|00001840| 73 20 61 20 6c 69 6e 65 | 20 6f 66 20 74 65 78 74 |s a line| of text|
|00001850| 20 77 69 74 68 6f 75 74 | 20 65 63 68 6f 69 6e 67 | without| echoing|
|00001860| 20 69 74 2c 0a 20 20 20 | 20 61 6e 64 20 73 65 6e | it,. | and sen|
|00001870| 64 73 20 69 74 20 74 6f | 20 74 68 65 20 73 68 65 |ds it to| the she|
|00001880| 6c 6c 2e 20 20 54 68 69 | 73 20 69 73 20 75 73 65 |ll. Thi|s is use|
|00001890| 66 75 6c 20 66 6f 72 20 | 65 6e 74 65 72 69 6e 67 |ful for |entering|
|000018a0| 20 70 61 73 73 77 6f 72 | 64 73 2e 0a 0a 49 66 20 | passwor|ds...If |
|000018b0| 79 6f 75 20 61 63 63 69 | 64 65 6e 74 61 6c 6c 79 |you acci|dentally|
|000018c0| 20 73 75 73 70 65 6e 64 | 20 79 6f 75 72 20 70 72 | suspend| your pr|
|000018d0| 6f 63 65 73 73 2c 20 75 | 73 65 20 5c 5c 5b 74 65 |ocess, u|se \\[te|
|000018e0| 72 6d 2d 63 6f 6e 74 69 | 6e 75 65 2d 73 75 62 6a |rm-conti|nue-subj|
|000018f0| 6f 62 5d 0a 74 6f 20 63 | 6f 6e 74 69 6e 75 65 20 |ob].to c|ontinue |
|00001900| 69 74 2e 0a 0a 63 64 2c | 20 70 75 73 68 64 20 61 |it...cd,| pushd a|
|00001910| 6e 64 20 70 6f 70 64 20 | 63 6f 6d 6d 61 6e 64 73 |nd popd |commands|
|00001920| 20 67 69 76 65 6e 20 74 | 6f 20 74 68 65 20 73 68 | given t|o the sh|
|00001930| 65 6c 6c 20 61 72 65 20 | 77 61 74 63 68 65 64 20 |ell are |watched |
|00001940| 62 79 20 45 6d 61 63 73 | 20 74 6f 20 6b 65 65 70 |by Emacs| to keep|
|00001950| 0a 74 68 69 73 20 62 75 | 66 66 65 72 27 73 20 64 |.this bu|ffer's d|
|00001960| 65 66 61 75 6c 74 20 64 | 69 72 65 63 74 6f 72 79 |efault d|irectory|
|00001970| 20 74 68 65 20 73 61 6d | 65 20 61 73 20 74 68 65 | the sam|e as the|
|00001980| 20 73 68 65 6c 6c 27 73 | 20 77 6f 72 6b 69 6e 67 | shell's| working|
|00001990| 20 64 69 72 65 63 74 6f | 72 79 2e 0a 4d 2d 78 20 | directo|ry..M-x |
|000019a0| 64 69 72 73 20 71 75 65 | 72 69 65 73 20 74 68 65 |dirs que|ries the|
|000019b0| 20 73 68 65 6c 6c 20 61 | 6e 64 20 72 65 73 79 6e | shell a|nd resyn|
|000019c0| 63 73 20 45 6d 61 63 73 | 27 20 69 64 65 61 20 6f |cs Emacs|' idea o|
|000019d0| 66 20 77 68 61 74 20 74 | 68 65 20 63 75 72 72 65 |f what t|he curre|
|000019e0| 6e 74 20 0a 20 20 20 20 | 64 69 72 65 63 74 6f 72 |nt . |director|
|000019f0| 79 20 73 74 61 63 6b 20 | 69 73 2e 0a 4d 2d 78 20 |y stack |is..M-x |
|00001a00| 64 69 72 74 72 61 63 6b | 2d 74 6f 67 67 6c 65 20 |dirtrack|-toggle |
|00001a10| 74 75 72 6e 73 20 64 69 | 72 65 63 74 6f 72 79 20 |turns di|rectory |
|00001a20| 74 72 61 63 6b 69 6e 67 | 20 6f 6e 20 61 6e 64 20 |tracking| on and |
|00001a30| 6f 66 66 2e 0a 0a 5c 5c | 7b 74 73 68 65 6c 6c 2d |off...\\|{tshell-|
|00001a40| 6d 6f 64 65 2d 6d 61 70 | 7d 0a 43 75 73 74 6f 6d |mode-map|}.Custom|
|00001a50| 69 7a 61 74 69 6f 6e 3a | 20 45 6e 74 72 79 20 74 |ization:| Entry t|
|00001a60| 6f 20 74 68 69 73 20 6d | 6f 64 65 20 72 75 6e 73 |o this m|ode runs|
|00001a70| 20 74 68 65 20 68 6f 6f | 6b 73 20 6f 6e 20 60 74 | the hoo|ks on `t|
|00001a80| 65 72 6d 2d 6d 6f 64 65 | 2d 68 6f 6f 6b 27 20 61 |erm-mode|-hook' a|
|00001a90| 6e 64 0a 60 74 73 68 65 | 6c 6c 2d 6d 6f 64 65 2d |nd.`tshe|ll-mode-|
|00001aa0| 68 6f 6f 6b 27 20 28 69 | 6e 20 74 68 61 74 20 6f |hook' (i|n that o|
|00001ab0| 72 64 65 72 29 2e 20 20 | 42 65 66 6f 72 65 20 65 |rder). |Before e|
|00001ac0| 61 63 68 20 69 6e 70 75 | 74 2c 20 74 68 65 20 68 |ach inpu|t, the h|
|00001ad0| 6f 6f 6b 73 20 6f 6e 0a | 60 74 65 72 6d 2d 69 6e |ooks on.|`term-in|
|00001ae0| 70 75 74 2d 66 69 6c 74 | 65 72 2d 66 75 6e 63 74 |put-filt|er-funct|
|00001af0| 69 6f 6e 73 27 20 61 72 | 65 20 72 75 6e 2e 0a 0a |ions' ar|e run...|
|00001b00| 56 61 72 69 61 62 6c 65 | 73 20 60 73 68 65 6c 6c |Variable|s `shell|
|00001b10| 2d 63 64 2d 72 65 67 65 | 78 70 27 2c 20 60 73 68 |-cd-rege|xp', `sh|
|00001b20| 65 6c 6c 2d 70 75 73 68 | 64 2d 72 65 67 65 78 70 |ell-push|d-regexp|
|00001b30| 27 20 61 6e 64 20 60 73 | 68 65 6c 6c 2d 70 6f 70 |' and `s|hell-pop|
|00001b40| 64 2d 72 65 67 65 78 70 | 27 0a 61 72 65 20 75 73 |d-regexp|'.are us|
|00001b50| 65 64 20 74 6f 20 6d 61 | 74 63 68 20 74 68 65 69 |ed to ma|tch thei|
|00001b60| 72 20 72 65 73 70 65 63 | 74 69 76 65 20 63 6f 6d |r respec|tive com|
|00001b70| 6d 61 6e 64 73 2c 20 77 | 68 69 6c 65 20 60 73 68 |mands, w|hile `sh|
|00001b80| 65 6c 6c 2d 70 75 73 68 | 64 2d 74 6f 68 6f 6d 65 |ell-push|d-tohome|
|00001b90| 27 2c 0a 60 73 68 65 6c | 6c 2d 70 75 73 68 64 2d |',.`shel|l-pushd-|
|00001ba0| 64 65 78 74 72 61 63 74 | 27 20 61 6e 64 20 60 73 |dextract|' and `s|
|00001bb0| 68 65 6c 6c 2d 70 75 73 | 68 64 2d 64 75 6e 69 71 |hell-pus|hd-duniq|
|00001bc0| 75 65 27 20 63 6f 6e 74 | 72 6f 6c 20 74 68 65 20 |ue' cont|rol the |
|00001bd0| 62 65 68 61 76 69 6f 72 | 20 6f 66 20 74 68 65 0a |behavior| of the.|
|00001be0| 72 65 6c 65 76 61 6e 74 | 20 63 6f 6d 6d 61 6e 64 |relevant| command|
|00001bf0| 2e 0a 0a 56 61 72 69 61 | 62 6c 65 73 20 60 74 65 |...Varia|bles `te|
|00001c00| 72 6d 2d 63 6f 6d 70 6c | 65 74 69 6f 6e 2d 61 75 |rm-compl|etion-au|
|00001c10| 74 6f 6c 69 73 74 27 2c | 20 60 74 65 72 6d 2d 63 |tolist',| `term-c|
|00001c20| 6f 6d 70 6c 65 74 69 6f | 6e 2d 61 64 64 73 75 66 |ompletio|n-addsuf|
|00001c30| 66 69 78 27 2c 0a 60 74 | 65 72 6d 2d 63 6f 6d 70 |fix',.`t|erm-comp|
|00001c40| 6c 65 74 69 6f 6e 2d 72 | 65 63 65 78 61 63 74 27 |letion-r|ecexact'|
|00001c50| 20 61 6e 64 20 60 74 65 | 72 6d 2d 63 6f 6d 70 6c | and `te|rm-compl|
|00001c60| 65 74 69 6f 6e 2d 66 69 | 67 6e 6f 72 65 27 20 63 |etion-fi|gnore' c|
|00001c70| 6f 6e 74 72 6f 6c 20 74 | 68 65 0a 62 65 68 61 76 |ontrol t|he.behav|
|00001c80| 69 6f 72 20 6f 66 20 66 | 69 6c 65 20 6e 61 6d 65 |ior of f|ile name|
|00001c90| 2c 20 63 6f 6d 6d 61 6e | 64 20 6e 61 6d 65 20 61 |, comman|d name a|
|00001ca0| 6e 64 20 76 61 72 69 61 | 62 6c 65 20 6e 61 6d 65 |nd varia|ble name|
|00001cb0| 20 63 6f 6d 70 6c 65 74 | 69 6f 6e 2e 20 20 56 61 | complet|ion. Va|
|00001cc0| 72 69 61 62 6c 65 0a 60 | 73 68 65 6c 6c 2d 63 6f |riable.`|shell-co|
|00001cd0| 6d 70 6c 65 74 69 6f 6e | 2d 65 78 65 63 6f 6e 6c |mpletion|-execonl|
|00001ce0| 79 27 20 63 6f 6e 74 72 | 6f 6c 73 20 74 68 65 20 |y' contr|ols the |
|00001cf0| 62 65 68 61 76 69 6f 72 | 20 6f 66 20 63 6f 6d 6d |behavior| of comm|
|00001d00| 61 6e 64 20 6e 61 6d 65 | 20 63 6f 6d 70 6c 65 74 |and name| complet|
|00001d10| 69 6f 6e 2e 0a 56 61 72 | 69 61 62 6c 65 20 60 74 |ion..Var|iable `t|
|00001d20| 73 68 65 6c 6c 2d 63 6f | 6d 70 6c 65 74 69 6f 6e |shell-co|mpletion|
|00001d30| 2d 66 69 67 6e 6f 72 65 | 27 20 69 73 20 75 73 65 |-fignore|' is use|
|00001d40| 64 20 74 6f 20 69 6e 69 | 74 69 61 6c 69 73 65 20 |d to ini|tialise |
|00001d50| 74 68 65 20 76 61 6c 75 | 65 20 6f 66 0a 60 74 65 |the valu|e of.`te|
|00001d60| 72 6d 2d 63 6f 6d 70 6c | 65 74 69 6f 6e 2d 66 69 |rm-compl|etion-fi|
|00001d70| 67 6e 6f 72 65 27 2e 0a | 0a 56 61 72 69 61 62 6c |gnore'..|.Variabl|
|00001d80| 65 73 20 60 74 65 72 6d | 2d 69 6e 70 75 74 2d 72 |es `term|-input-r|
|00001d90| 69 6e 67 2d 66 69 6c 65 | 2d 6e 61 6d 65 27 20 61 |ing-file|-name' a|
|00001da0| 6e 64 20 60 74 65 72 6d | 2d 69 6e 70 75 74 2d 61 |nd `term|-input-a|
|00001db0| 75 74 6f 65 78 70 61 6e | 64 27 20 63 6f 6e 74 72 |utoexpan|d' contr|
|00001dc0| 6f 6c 0a 74 68 65 20 69 | 6e 69 74 69 61 6c 69 73 |ol.the i|nitialis|
|00001dd0| 61 74 69 6f 6e 20 6f 66 | 20 74 68 65 20 69 6e 70 |ation of| the inp|
|00001de0| 75 74 20 72 69 6e 67 20 | 68 69 73 74 6f 72 79 2c |ut ring |history,|
|00001df0| 20 61 6e 64 20 68 69 73 | 74 6f 72 79 20 65 78 70 | and his|tory exp|
|00001e00| 61 6e 73 69 6f 6e 2e 0a | 0a 56 61 72 69 61 62 6c |ansion..|.Variabl|
|00001e10| 65 73 20 60 74 65 72 6d | 2d 6f 75 74 70 75 74 2d |es `term|-output-|
|00001e20| 66 69 6c 74 65 72 2d 66 | 75 6e 63 74 69 6f 6e 73 |filter-f|unctions|
|00001e30| 27 2c 20 61 20 68 6f 6f | 6b 2c 20 61 6e 64 0a 60 |', a hoo|k, and.`|
|00001e40| 74 65 72 6d 2d 73 63 72 | 6f 6c 6c 2d 74 6f 2d 62 |term-scr|oll-to-b|
|00001e50| 6f 74 74 6f 6d 2d 6f 6e | 2d 69 6e 70 75 74 27 20 |ottom-on|-input' |
|00001e60| 61 6e 64 20 60 74 65 72 | 6d 2d 73 63 72 6f 6c 6c |and `ter|m-scroll|
|00001e70| 2d 74 6f 2d 62 6f 74 74 | 6f 6d 2d 6f 6e 2d 6f 75 |-to-bott|om-on-ou|
|00001e80| 74 70 75 74 27 0a 63 6f | 6e 74 72 6f 6c 20 77 68 |tput'.co|ntrol wh|
|00001e90| 65 74 68 65 72 20 69 6e | 70 75 74 20 61 6e 64 20 |ether in|put and |
|00001ea0| 6f 75 74 70 75 74 20 63 | 61 75 73 65 20 74 68 65 |output c|ause the|
|00001eb0| 20 77 69 6e 64 6f 77 20 | 74 6f 20 73 63 72 6f 6c | window |to scrol|
|00001ec0| 6c 20 74 6f 20 74 68 65 | 20 65 6e 64 20 6f 66 20 |l to the| end of |
|00001ed0| 74 68 65 0a 62 75 66 66 | 65 72 2e 22 20 6e 69 6c |the.buff|er." nil|
|00001ee0| 5d 29 0a 28 66 73 65 74 | 20 27 74 73 68 65 6c 6c |]).(fset| 'tshell|
|00001ef0| 20 23 5b 6e 69 6c 20 22 | c0 c1 21 ac c9 5c 6e ae | #[nil "|..!..\n.|
|00001f00| 8b c3 c4 21 ae 86 c3 c5 | 21 ae 81 c6 1e 07 c8 0e |...!....|!.......|
|00001f10| 07 21 1e 09 ca 0e 09 50 | 1e 0b cc cd 0e 09 ce 51 |.!.....P|.......Q|
|00001f20| 21 1e 0f d0 d1 d2 0e 07 | d3 0e 0b 21 ad 82 0e 0b |!.......|...!....|
|00001f30| 0e 0f ab 8b d4 0e 0f 21 | ab 85 0e 0f 4a aa 81 d5 |.......!|....J...|
|00001f40| 25 71 88 d6 20 88 2c d7 | c1 21 87 22 20 5b 74 65 |%q.. .,.|.!." [te|
|00001f50| 72 6d 2d 63 68 65 63 6b | 2d 70 72 6f 63 20 22 2a |rm-check|-proc "*|
|00001f60| 73 68 65 6c 6c 2a 22 20 | 65 78 70 6c 69 63 69 74 |shell*" |explicit|
|00001f70| 2d 73 68 65 6c 6c 2d 66 | 69 6c 65 2d 6e 61 6d 65 |-shell-f|ile-name|
|00001f80| 20 67 65 74 65 6e 76 20 | 22 45 53 48 45 4c 4c 22 | getenv |"ESHELL"|
|00001f90| 20 22 53 48 45 4c 4c 22 | 20 22 2f 62 69 6e 2f 73 | "SHELL"| "/bin/s|
|00001fa0| 68 22 20 70 72 6f 67 20 | 66 69 6c 65 2d 6e 61 6d |h" prog |file-nam|
|00001fb0| 65 2d 6e 6f 6e 64 69 72 | 65 63 74 6f 72 79 20 6e |e-nondir|ectory n|
|00001fc0| 61 6d 65 20 22 7e 2f 2e | 65 6d 61 63 73 5f 22 20 |ame "~/.|emacs_" |
|00001fd0| 73 74 61 72 74 66 69 6c | 65 20 69 6e 74 65 72 6e |startfil|e intern|
|00001fe0| 2d 73 6f 66 74 20 22 65 | 78 70 6c 69 63 69 74 2d |-soft "e|xplicit-|
|00001ff0| 22 20 22 2d 61 72 67 73 | 22 20 78 61 72 67 73 2d |" "-args|" xargs-|
|00002000| 6e 61 6d 65 20 61 70 70 | 6c 79 20 6d 61 6b 65 2d |name app|ly make-|
|00002010| 74 65 72 6d 20 22 73 68 | 65 6c 6c 22 20 66 69 6c |term "sh|ell" fil|
|00002020| 65 2d 65 78 69 73 74 73 | 2d 70 20 62 6f 75 6e 64 |e-exists|-p bound|
|00002030| 70 20 28 22 2d 69 22 29 | 20 74 73 68 65 6c 6c 2d |p ("-i")| tshell-|
|00002040| 6d 6f 64 65 20 73 77 69 | 74 63 68 2d 74 6f 2d 62 |mode swi|tch-to-b|
|00002050| 75 66 66 65 72 5d 20 37 | 20 22 5c 0a 52 75 6e 20 |uffer] 7| "\.Run |
|00002060| 61 6e 20 69 6e 66 65 72 | 69 6f 72 20 73 68 65 6c |an infer|ior shel|
|00002070| 6c 2c 20 77 69 74 68 20 | 49 2f 4f 20 74 68 72 6f |l, with |I/O thro|
|00002080| 75 67 68 20 62 75 66 66 | 65 72 20 2a 73 68 65 6c |ugh buff|er *shel|
|00002090| 6c 2a 2e 0a 49 66 20 62 | 75 66 66 65 72 20 65 78 |l*..If b|uffer ex|
|000020a0| 69 73 74 73 20 62 75 74 | 20 73 68 65 6c 6c 20 70 |ists but| shell p|
|000020b0| 72 6f 63 65 73 73 20 69 | 73 20 6e 6f 74 20 72 75 |rocess i|s not ru|
|000020c0| 6e 6e 69 6e 67 2c 20 6d | 61 6b 65 20 6e 65 77 20 |nning, m|ake new |
|000020d0| 73 68 65 6c 6c 2e 0a 49 | 66 20 62 75 66 66 65 72 |shell..I|f buffer|
|000020e0| 20 65 78 69 73 74 73 20 | 61 6e 64 20 73 68 65 6c | exists |and shel|
|000020f0| 6c 20 70 72 6f 63 65 73 | 73 20 69 73 20 72 75 6e |l proces|s is run|
|00002100| 6e 69 6e 67 2c 20 6a 75 | 73 74 20 73 77 69 74 63 |ning, ju|st switc|
|00002110| 68 20 74 6f 20 62 75 66 | 66 65 72 20 60 2a 73 68 |h to buf|fer `*sh|
|00002120| 65 6c 6c 2a 27 2e 0a 50 | 72 6f 67 72 61 6d 20 75 |ell*'..P|rogram u|
|00002130| 73 65 64 20 63 6f 6d 65 | 73 20 66 72 6f 6d 20 76 |sed come|s from v|
|00002140| 61 72 69 61 62 6c 65 20 | 60 65 78 70 6c 69 63 69 |ariable |`explici|
|00002150| 74 2d 73 68 65 6c 6c 2d | 66 69 6c 65 2d 6e 61 6d |t-shell-|file-nam|
|00002160| 65 27 2c 0a 20 6f 72 20 | 28 69 66 20 74 68 61 74 |e',. or |(if that|
|00002170| 20 69 73 20 6e 69 6c 29 | 20 66 72 6f 6d 20 74 68 | is nil)| from th|
|00002180| 65 20 45 53 48 45 4c 4c | 20 65 6e 76 69 72 6f 6e |e ESHELL| environ|
|00002190| 6d 65 6e 74 20 76 61 72 | 69 61 62 6c 65 2c 0a 20 |ment var|iable,. |
|000021a0| 6f 72 20 65 6c 73 65 20 | 66 72 6f 6d 20 53 48 45 |or else |from SHE|
|000021b0| 4c 4c 20 69 66 20 74 68 | 65 72 65 20 69 73 20 6e |LL if th|ere is n|
|000021c0| 6f 20 45 53 48 45 4c 4c | 2e 0a 49 66 20 61 20 66 |o ESHELL|..If a f|
|000021d0| 69 6c 65 20 60 7e 2f 2e | 65 6d 61 63 73 5f 53 48 |ile `~/.|emacs_SH|
|000021e0| 45 4c 4c 4e 41 4d 45 27 | 20 65 78 69 73 74 73 2c |ELLNAME'| exists,|
|000021f0| 20 69 74 20 69 73 20 67 | 69 76 65 6e 20 61 73 20 | it is g|iven as |
|00002200| 69 6e 69 74 69 61 6c 20 | 69 6e 70 75 74 0a 20 28 |initial |input. (|
|00002210| 4e 6f 74 65 20 74 68 61 | 74 20 74 68 69 73 20 6d |Note tha|t this m|
|00002220| 61 79 20 6c 6f 73 65 20 | 64 75 65 20 74 6f 20 61 |ay lose |due to a|
|00002230| 20 74 69 6d 69 6e 67 20 | 65 72 72 6f 72 20 69 66 | timing |error if|
|00002240| 20 74 68 65 20 73 68 65 | 6c 6c 0a 20 20 64 69 73 | the she|ll. dis|
|00002250| 63 61 72 64 73 20 69 6e | 70 75 74 20 77 68 65 6e |cards in|put when|
|00002260| 20 69 74 20 73 74 61 72 | 74 73 20 75 70 2e 29 0a | it star|ts up.).|
|00002270| 54 68 65 20 62 75 66 66 | 65 72 20 69 73 20 70 75 |The buff|er is pu|
|00002280| 74 20 69 6e 20 54 73 68 | 65 6c 6c 20 6d 6f 64 65 |t in Tsh|ell mode|
|00002290| 2c 20 67 69 76 69 6e 67 | 20 63 6f 6d 6d 61 6e 64 |, giving| command|
|000022a0| 73 20 66 6f 72 20 73 65 | 6e 64 69 6e 67 20 69 6e |s for se|nding in|
|000022b0| 70 75 74 0a 61 6e 64 20 | 63 6f 6e 74 72 6f 6c 6c |put.and |controll|
|000022c0| 69 6e 67 20 74 68 65 20 | 73 75 62 6a 6f 62 73 20 |ing the |subjobs |
|000022d0| 6f 66 20 74 68 65 20 73 | 68 65 6c 6c 2e 20 20 53 |of the s|hell. S|
|000022e0| 65 65 20 60 74 73 68 65 | 6c 6c 2d 6d 6f 64 65 27 |ee `tshe|ll-mode'|
|000022f0| 2e 0a 53 65 65 20 61 6c | 73 6f 20 74 68 65 20 76 |..See al|so the v|
|00002300| 61 72 69 61 62 6c 65 20 | 60 74 73 68 65 6c 6c 2d |ariable |`tshell-|
|00002310| 70 72 6f 6d 70 74 2d 70 | 61 74 74 65 72 6e 27 2e |prompt-p|attern'.|
|00002320| 0a 0a 54 68 65 20 73 68 | 65 6c 6c 20 66 69 6c 65 |..The sh|ell file|
|00002330| 20 6e 61 6d 65 20 28 73 | 61 6e 73 20 64 69 72 65 | name (s|ans dire|
|00002340| 63 74 6f 72 69 65 73 29 | 20 69 73 20 75 73 65 64 |ctories)| is used|
|00002350| 20 74 6f 20 6d 61 6b 65 | 20 61 20 73 79 6d 62 6f | to make| a symbo|
|00002360| 6c 20 6e 61 6d 65 0a 73 | 75 63 68 20 61 73 20 60 |l name.s|uch as `|
|00002370| 65 78 70 6c 69 63 69 74 | 2d 63 73 68 2d 61 72 67 |explicit|-csh-arg|
|00002380| 73 27 2e 20 20 49 66 20 | 74 68 61 74 20 73 79 6d |s'. If |that sym|
|00002390| 62 6f 6c 20 69 73 20 61 | 20 76 61 72 69 61 62 6c |bol is a| variabl|
|000023a0| 65 2c 0a 69 74 73 20 76 | 61 6c 75 65 20 69 73 20 |e,.its v|alue is |
|000023b0| 75 73 65 64 20 61 73 20 | 61 20 6c 69 73 74 20 6f |used as |a list o|
|000023c0| 66 20 61 72 67 75 6d 65 | 6e 74 73 20 77 68 65 6e |f argume|nts when|
|000023d0| 20 69 6e 76 6f 6b 69 6e | 67 20 74 68 65 20 73 68 | invokin|g the sh|
|000023e0| 65 6c 6c 2e 0a 4f 74 68 | 65 72 77 69 73 65 2c 20 |ell..Oth|erwise, |
|000023f0| 6f 6e 65 20 61 72 67 75 | 6d 65 6e 74 20 60 2d 69 |one argu|ment `-i|
|00002400| 27 20 69 73 20 70 61 73 | 73 65 64 20 74 6f 20 74 |' is pas|sed to t|
|00002410| 68 65 20 73 68 65 6c 6c | 2e 0a 0a 28 54 79 70 65 |he shell|...(Type|
|00002420| 20 5c 5c 5b 64 65 73 63 | 72 69 62 65 2d 6d 6f 64 | \\[desc|ribe-mod|
|00002430| 65 5d 20 69 6e 20 74 68 | 65 20 73 68 65 6c 6c 20 |e] in th|e shell |
|00002440| 62 75 66 66 65 72 20 66 | 6f 72 20 61 20 6c 69 73 |buffer f|or a lis|
|00002450| 74 20 6f 66 20 63 6f 6d | 6d 61 6e 64 73 2e 29 22 |t of com|mands.)"|
|00002460| 20 6e 69 6c 5d 29 0a 28 | 66 73 65 74 20 27 74 73 | nil]).(|fset 'ts|
|00002470| 68 65 6c 6c 2d 64 69 72 | 65 63 74 6f 72 79 2d 74 |hell-dir|ectory-t|
|00002480| 72 61 63 6b 65 72 20 23 | 5b 28 73 74 72 29 20 22 |racker #|[(str) "|
|00002490| 08 ad 84 c1 c2 c3 8f 87 | 22 20 5b 74 73 68 65 6c |........|" [tshel|
|000024a0| 6c 2d 64 69 72 74 72 61 | 63 6b 70 20 63 68 64 69 |l-dirtra|ckp chdi|
|000024b0| 72 2d 66 61 69 6c 75 72 | 65 20 28 62 79 74 65 2d |r-failur|e (byte-|
|000024c0| 63 6f 64 65 20 22 c0 c1 | 5c 6e 5c 22 88 c3 95 c4 |code "..|\n\"....|
|000024d0| 89 89 1d 1e 06 1e 07 1e | 08 c0 0e 09 5c 6e 0e 08 |........|....\n..|
|000024e0| 23 ad dc c3 95 16 07 ca | 5c 6e 0e 08 0e 07 4f c3 |#.......|\n....O.|
|000024f0| 89 23 16 06 ca 5c 6e 0e | 08 0e 07 4f cb 89 23 15 |.#...\n.|...O..#.|
|00002500| c0 0e 0c 0e 06 5c 22 c3 | 3d ab 88 cd ce 0d 21 21 |.....\".|=.....!!|
|00002510| 88 aa a2 c0 0e 0f 0e 06 | 5c 22 c3 3d ab 88 d0 ce |........|\".=....|
|00002520| 0d 21 21 88 aa 90 c0 0e | 11 0e 06 5c 22 c3 3d ab |.!!.....|...\".=.|
|00002530| 86 d2 ce 0d 21 21 88 c0 | d3 5c 6e 0e 07 23 88 c3 |....!!..|.\n..#..|
|00002540| 95 16 08 aa 1b 2c 87 22 | 20 5b 73 74 72 69 6e 67 |.....,."| [string|
|00002550| 2d 6d 61 74 63 68 20 22 | 5e 5b 3b 5c 5c 73 20 5d |-match "|^[;\\s ]|
|00002560| 2a 22 20 73 74 72 20 30 | 20 6e 69 6c 20 61 72 67 |*" str 0| nil arg|
|00002570| 31 20 63 6d 64 20 65 6e | 64 20 73 74 61 72 74 20 |1 cmd en|d start |
|00002580| 73 68 65 6c 6c 2d 63 6f | 6d 6d 61 6e 64 2d 72 65 |shell-co|mmand-re|
|00002590| 67 65 78 70 20 74 65 72 | 6d 2d 61 72 67 75 6d 65 |gexp ter|m-argume|
|000025a0| 6e 74 73 20 31 20 73 68 | 65 6c 6c 2d 70 6f 70 64 |nts 1 sh|ell-popd|
|000025b0| 2d 72 65 67 65 78 70 20 | 74 73 68 65 6c 6c 2d 70 |-regexp |tshell-p|
|000025c0| 72 6f 63 65 73 73 2d 70 | 6f 70 64 20 73 75 62 73 |rocess-p|opd subs|
|000025d0| 74 69 74 75 74 65 2d 69 | 6e 2d 66 69 6c 65 2d 6e |titute-i|n-file-n|
|000025e0| 61 6d 65 20 73 68 65 6c | 6c 2d 70 75 73 68 64 2d |ame shel|l-pushd-|
|000025f0| 72 65 67 65 78 70 20 74 | 73 68 65 6c 6c 2d 70 72 |regexp t|shell-pr|
|00002600| 6f 63 65 73 73 2d 70 75 | 73 68 64 20 73 68 65 6c |ocess-pu|shd shel|
|00002610| 6c 2d 63 64 2d 72 65 67 | 65 78 70 20 74 73 68 65 |l-cd-reg|exp tshe|
|00002620| 6c 6c 2d 70 72 6f 63 65 | 73 73 2d 63 64 20 22 5b |ll-proce|ss-cd "[|
|00002630| 3b 5c 5c 73 20 5d 2a 22 | 5d 20 34 29 20 28 28 65 |;\\s ]*"|] 4) ((e|
|00002640| 72 72 6f 72 20 22 43 6f | 75 6c 64 6e 27 74 20 63 |rror "Co|uldn't c|
|00002650| 64 22 29 29 5d 20 33 20 | 22 5c 0a 54 72 61 63 6b |d"))] 3 |"\.Track|
|00002660| 73 20 63 64 2c 20 70 75 | 73 68 64 20 61 6e 64 20 |s cd, pu|shd and |
|00002670| 70 6f 70 64 20 63 6f 6d | 6d 61 6e 64 73 20 69 73 |popd com|mands is|
|00002680| 73 75 65 64 20 74 6f 20 | 74 68 65 20 73 68 65 6c |sued to |the shel|
|00002690| 6c 2e 0a 54 68 69 73 20 | 66 75 6e 63 74 69 6f 6e |l..This |function|
|000026a0| 20 69 73 20 63 61 6c 6c | 65 64 20 6f 6e 20 65 61 | is call|ed on ea|
|000026b0| 63 68 20 69 6e 70 75 74 | 20 70 61 73 73 65 64 20 |ch input| passed |
|000026c0| 74 6f 20 74 68 65 20 73 | 68 65 6c 6c 2e 0a 49 74 |to the s|hell..It|
|000026d0| 20 77 61 74 63 68 65 73 | 20 66 6f 72 20 63 64 2c | watches| for cd,|
|000026e0| 20 70 75 73 68 64 20 61 | 6e 64 20 70 6f 70 64 20 | pushd a|nd popd |
|000026f0| 63 6f 6d 6d 61 6e 64 73 | 20 61 6e 64 20 73 65 74 |commands| and set|
|00002700| 73 20 74 68 65 20 62 75 | 66 66 65 72 27 73 0a 64 |s the bu|ffer's.d|
|00002710| 65 66 61 75 6c 74 20 64 | 69 72 65 63 74 6f 72 79 |efault d|irectory|
|00002720| 20 74 6f 20 74 72 61 63 | 6b 20 74 68 65 73 65 20 | to trac|k these |
|00002730| 63 6f 6d 6d 61 6e 64 73 | 2e 0a 0a 59 6f 75 20 6d |commands|...You m|
|00002740| 61 79 20 74 6f 67 67 6c | 65 20 74 68 69 73 20 74 |ay toggl|e this t|
|00002750| 72 61 63 6b 69 6e 67 20 | 6f 6e 20 61 6e 64 20 6f |racking |on and o|
|00002760| 66 66 20 77 69 74 68 20 | 4d 2d 78 20 64 69 72 74 |ff with |M-x dirt|
|00002770| 72 61 63 6b 2d 74 6f 67 | 67 6c 65 2e 0a 49 66 20 |rack-tog|gle..If |
|00002780| 65 6d 61 63 73 20 67 65 | 74 73 20 63 6f 6e 66 75 |emacs ge|ts confu|
|00002790| 73 65 64 2c 20 79 6f 75 | 20 63 61 6e 20 72 65 73 |sed, you| can res|
|000027a0| 79 6e 63 20 77 69 74 68 | 20 74 68 65 20 73 68 65 |ync with| the she|
|000027b0| 6c 6c 20 77 69 74 68 20 | 4d 2d 78 20 64 69 72 73 |ll with |M-x dirs|
|000027c0| 2e 0a 0a 53 65 65 20 76 | 61 72 69 61 62 6c 65 73 |...See v|ariables|
|000027d0| 20 60 73 68 65 6c 6c 2d | 63 64 2d 72 65 67 65 78 | `shell-|cd-regex|
|000027e0| 70 27 2c 20 60 73 68 65 | 6c 6c 2d 70 75 73 68 64 |p', `she|ll-pushd|
|000027f0| 2d 72 65 67 65 78 70 27 | 2c 20 61 6e 64 20 60 73 |-regexp'|, and `s|
|00002800| 68 65 6c 6c 2d 70 6f 70 | 64 2d 72 65 67 65 78 70 |hell-pop|d-regexp|
|00002810| 27 2c 0a 77 68 69 6c 65 | 20 60 73 68 65 6c 6c 2d |',.while| `shell-|
|00002820| 70 75 73 68 64 2d 74 6f | 68 6f 6d 65 27 2c 20 60 |pushd-to|home', `|
|00002830| 73 68 65 6c 6c 2d 70 75 | 73 68 64 2d 64 65 78 74 |shell-pu|shd-dext|
|00002840| 72 61 63 74 27 20 61 6e | 64 20 60 73 68 65 6c 6c |ract' an|d `shell|
|00002850| 2d 70 75 73 68 64 2d 64 | 75 6e 69 71 75 65 27 0a |-pushd-d|unique'.|
|00002860| 63 6f 6e 74 72 6f 6c 20 | 74 68 65 20 62 65 68 61 |control |the beha|
|00002870| 76 69 6f 72 20 6f 66 20 | 74 68 65 20 72 65 6c 65 |vior of |the rele|
|00002880| 76 61 6e 74 20 63 6f 6d | 6d 61 6e 64 2e 0a 0a 45 |vant com|mand...E|
|00002890| 6e 76 69 72 6f 6e 6d 65 | 6e 74 20 76 61 72 69 61 |nvironme|nt varia|
|000028a0| 62 6c 65 73 20 61 72 65 | 20 65 78 70 61 6e 64 65 |bles are| expande|
|000028b0| 64 2c 20 73 65 65 20 66 | 75 6e 63 74 69 6f 6e 20 |d, see f|unction |
|000028c0| 60 73 75 62 73 74 69 74 | 75 74 65 2d 69 6e 2d 66 |`substit|ute-in-f|
|000028d0| 69 6c 65 2d 6e 61 6d 65 | 27 2e 22 5d 29 0a 28 62 |ile-name|'."]).(b|
|000028e0| 79 74 65 2d 63 6f 64 65 | 20 22 c0 c1 4d 88 c2 c3 |yte-code| "..M...|
|000028f0| 4d 88 c4 c5 4d 88 c6 c7 | 4d 88 c8 c9 4d 87 22 20 |M...M...|M...M." |
|00002900| 5b 74 73 68 65 6c 6c 2d | 70 72 6f 63 65 73 73 2d |[tshell-|process-|
|00002910| 70 6f 70 64 20 23 5b 28 | 61 72 67 29 20 22 c0 09 |popd #[(|arg) "..|
|00002920| 21 ae 81 c2 89 1b ab 94 | 0b c2 55 ab 8f 0c ab 8c |!.......|..U.....|
|00002930| c5 0c 40 21 88 0c 41 14 | c6 20 aa ac 0b ab a6 0b |..@!..A.|. ......|
|00002940| c2 56 ab a1 0b 0c 47 58 | ab 9b c7 0c 42 1e 08 0b |.V....GX|....B...|
|00002950| 53 0e 08 9b 89 1e 09 89 | 41 41 a1 88 0e 08 41 14 |S.......|AA....A.|
|00002960| c6 20 2a aa 83 ca cb 21 | 29 87 22 20 5b 74 73 68 |. *....!|)." [tsh|
|00002970| 65 6c 6c 2d 65 78 74 72 | 61 63 74 2d 6e 75 6d 20 |ell-extr|act-num |
|00002980| 61 72 67 20 30 20 6e 75 | 6d 20 74 73 68 65 6c 6c |arg 0 nu|m tshell|
|00002990| 2d 64 69 72 73 74 61 63 | 6b 20 63 64 20 74 73 68 |-dirstac|k cd tsh|
|000029a0| 65 6c 6c 2d 64 69 72 73 | 74 61 63 6b 2d 6d 65 73 |ell-dirs|tack-mes|
|000029b0| 73 61 67 65 20 6e 69 6c | 20 64 73 20 63 65 6c 6c |sage nil| ds cell|
|000029c0| 20 65 72 72 6f 72 20 22 | 43 6f 75 6c 64 6e 27 74 | error "|Couldn't|
|000029d0| 20 70 6f 70 64 22 5d 20 | 33 5d 20 74 73 68 65 6c | popd"] |3] tshel|
|000029e0| 6c 2d 70 72 65 66 69 78 | 65 64 2d 64 69 72 65 63 |l-prefix|ed-direc|
|000029f0| 74 6f 72 79 2d 6e 61 6d | 65 20 23 5b 28 64 69 72 |tory-nam|e #[(dir|
|00002a00| 29 20 22 08 47 c1 55 ab | 82 5c 6e 87 c3 5c 6e 21 |) ".G.U.|.\n..\n!|
|00002a10| ab 84 08 5c 6e 50 87 c4 | 5c 6e 21 87 22 20 5b 74 |...\nP..|\n!." [t|
|00002a20| 65 72 6d 2d 66 69 6c 65 | 2d 6e 61 6d 65 2d 70 72 |erm-file|-name-pr|
|00002a30| 65 66 69 78 20 30 20 64 | 69 72 20 66 69 6c 65 2d |efix 0 d|ir file-|
|00002a40| 6e 61 6d 65 2d 61 62 73 | 6f 6c 75 74 65 2d 70 20 |name-abs|olute-p |
|00002a50| 65 78 70 61 6e 64 2d 66 | 69 6c 65 2d 6e 61 6d 65 |expand-f|ile-name|
|00002a60| 5d 20 32 5d 20 74 73 68 | 65 6c 6c 2d 70 72 6f 63 |] 2] tsh|ell-proc|
|00002a70| 65 73 73 2d 63 64 20 23 | 5b 28 61 72 67 29 20 22 |ess-cd #|[(arg) "|
|00002a80| 08 47 c1 55 ab 85 5c 6e | c3 50 aa 8b 08 c4 98 ab |.G.U..\n|.P......|
|00002a90| 83 0d aa 83 c6 08 21 1e | 07 0e 08 15 c9 0e 07 21 |......!.|.......!|
|00002aa0| 88 ca 20 29 87 22 20 5b | 61 72 67 20 30 20 74 65 |.. )." [|arg 0 te|
|00002ab0| 72 6d 2d 66 69 6c 65 2d | 6e 61 6d 65 2d 70 72 65 |rm-file-|name-pre|
|00002ac0| 66 69 78 20 22 7e 22 20 | 22 2d 22 20 74 73 68 65 |fix "~" |"-" tshe|
|00002ad0| 6c 6c 2d 6c 61 73 74 2d | 64 69 72 20 74 73 68 65 |ll-last-|dir tshe|
|00002ae0| 6c 6c 2d 70 72 65 66 69 | 78 65 64 2d 64 69 72 65 |ll-prefi|xed-dire|
|00002af0| 63 74 6f 72 79 2d 6e 61 | 6d 65 20 6e 65 77 2d 64 |ctory-na|me new-d|
|00002b00| 69 72 20 64 65 66 61 75 | 6c 74 2d 64 69 72 65 63 |ir defau|lt-direc|
|00002b10| 74 6f 72 79 20 63 64 20 | 74 73 68 65 6c 6c 2d 64 |tory cd |tshell-d|
|00002b20| 69 72 73 74 61 63 6b 2d | 6d 65 73 73 61 67 65 5d |irstack-|message]|
|00002b30| 20 32 5d 20 74 73 68 65 | 6c 6c 2d 70 72 6f 63 65 | 2] tshe|ll-proce|
|00002b40| 73 73 2d 70 75 73 68 64 | 20 23 5b 28 61 72 67 29 |ss-pushd| #[(arg)|
|00002b50| 20 22 c0 09 21 1a 09 47 | c3 55 ab ae 0c ab 89 c5 | "..!..G|.U......|
|00002b60| 0e 06 c7 50 21 82 c7 00 | 0e 08 ab 98 0e 09 1e 5c |...P!...|.......\|
|00002b70| 6e cb 0e 08 40 21 88 0e | 5c 6e 0e 08 41 42 16 08 |n...@!..|\n..AB..|
|00002b80| cc 20 29 82 c7 00 cd ce | 21 82 c7 00 5c 6e a7 ab |. ).....|!...\n..|
|00002b90| ec 5c 6e 0e 08 47 56 ab | 85 cd cf 21 aa ff 5c 6e |.\n..GV.|...!..\n|
|00002ba0| c3 55 ab 87 d0 cd d1 21 | 21 aa f3 0e 12 ab 9a 5c |.U.....!|!......\|
|00002bb0| 6e 53 0e 08 38 1e 13 d4 | 09 21 88 d5 0e 09 21 88 |nS..8...|.!....!.|
|00002bc0| cb 0e 13 21 88 cc 20 29 | aa d5 0e 09 0e 08 42 89 |...!.. )|......B.|
|00002bd0| 1e 16 47 1e 17 5c 6e 0e | 16 9b 1e 18 d9 0e 17 5c |..G..\n.|.......\|
|00002be0| 6e 5a d9 0e 16 21 9b 21 | 1e 1a db 0e 18 0e 1a 5c |nZ...!.!|.......\|
|00002bf0| 22 1e 1c cb 0e 1c 40 21 | 88 0e 1c 41 16 08 cc 20 |".....@!|...A... |
|00002c00| 2d aa 9f 0e 09 1e 1d cb | de 09 21 21 88 0e 1f ab |-.......|..!!....|
|00002c10| 87 0e 1d 0e 08 9d ac 87 | 0e 1d 0e 08 42 16 08 cc |........|....B...|
|00002c20| 20 29 29 87 22 20 5b 74 | 73 68 65 6c 6c 2d 65 78 | ))." [t|shell-ex|
|00002c30| 74 72 61 63 74 2d 6e 75 | 6d 20 61 72 67 20 6e 75 |tract-nu|m arg nu|
|00002c40| 6d 20 30 20 73 68 65 6c | 6c 2d 70 75 73 68 64 2d |m 0 shel|l-pushd-|
|00002c50| 74 6f 68 6f 6d 65 20 73 | 68 65 6c 6c 2d 70 72 6f |tohome s|hell-pro|
|00002c60| 63 65 73 73 2d 70 75 73 | 68 64 20 74 65 72 6d 2d |cess-pus|hd term-|
|00002c70| 66 69 6c 65 2d 6e 61 6d | 65 2d 70 72 65 66 69 78 |file-nam|e-prefix|
|00002c80| 20 22 7e 22 20 74 73 68 | 65 6c 6c 2d 64 69 72 73 | "~" tsh|ell-dirs|
|00002c90| 74 61 63 6b 20 64 65 66 | 61 75 6c 74 2d 64 69 72 |tack def|ault-dir|
|00002ca0| 65 63 74 6f 72 79 20 6f | 6c 64 20 63 64 20 74 73 |ectory o|ld cd ts|
|00002cb0| 68 65 6c 6c 2d 64 69 72 | 73 74 61 63 6b 2d 6d 65 |hell-dir|stack-me|
|00002cc0| 73 73 61 67 65 20 6d 65 | 73 73 61 67 65 20 22 44 |ssage me|ssage "D|
|00002cd0| 69 72 65 63 74 6f 72 79 | 20 73 74 61 63 6b 20 65 |irectory| stack e|
|00002ce0| 6d 70 74 79 2e 22 20 22 | 44 69 72 65 63 74 6f 72 |mpty." "|Director|
|00002cf0| 79 20 73 74 61 63 6b 20 | 6e 6f 74 20 74 68 61 74 |y stack |not that|
|00002d00| 20 64 65 65 70 2e 22 20 | 65 72 72 6f 72 20 22 43 | deep." |error "C|
|00002d10| 6f 75 6c 64 6e 27 74 20 | 63 64 2e 22 20 73 68 65 |ouldn't |cd." she|
|00002d20| 6c 6c 2d 70 75 73 68 64 | 2d 64 65 78 74 72 61 63 |ll-pushd|-dextrac|
|00002d30| 74 20 64 69 72 20 74 73 | 68 65 6c 6c 2d 70 72 6f |t dir ts|hell-pro|
|00002d40| 63 65 73 73 2d 70 6f 70 | 64 20 74 73 68 65 6c 6c |cess-pop|d tshell|
|00002d50| 2d 70 72 6f 63 65 73 73 | 2d 70 75 73 68 64 20 64 |-process|-pushd d|
|00002d60| 73 20 64 73 6c 65 6e 20 | 66 72 6f 6e 74 20 72 65 |s dslen |front re|
|00002d70| 76 65 72 73 65 20 62 61 | 63 6b 20 61 70 70 65 6e |verse ba|ck appen|
|00002d80| 64 20 6e 65 77 2d 64 73 | 20 6f 6c 64 2d 77 64 20 |d new-ds| old-wd |
|00002d90| 74 73 68 65 6c 6c 2d 70 | 72 65 66 69 78 65 64 2d |tshell-p|refixed-|
|00002da0| 64 69 72 65 63 74 6f 72 | 79 2d 6e 61 6d 65 20 73 |director|y-name s|
|00002db0| 68 65 6c 6c 2d 70 75 73 | 68 64 2d 64 75 6e 69 71 |hell-pus|hd-duniq|
|00002dc0| 75 65 5d 20 35 5d 20 74 | 73 68 65 6c 6c 2d 65 78 |ue] 5] t|shell-ex|
|00002dd0| 74 72 61 63 74 2d 6e 75 | 6d 20 23 5b 28 73 74 72 |tract-nu|m #[(str|
|00002de0| 29 20 22 c0 c1 5c 6e 5c | 22 ad 83 c3 5c 6e 21 87 |) "..\n\|"...\n!.|
|00002df0| 22 20 5b 73 74 72 69 6e | 67 2d 6d 61 74 63 68 20 |" [strin|g-match |
|00002e00| 22 5e 5c 5c 2b 5b 31 2d | 39 5d 5b 30 2d 39 5d 2a |"^\\+[1-|9][0-9]*|
|00002e10| 24 22 20 73 74 72 20 73 | 74 72 69 6e 67 2d 74 6f |$" str s|tring-to|
|00002e20| 2d 69 6e 74 5d 20 33 5d | 5d 20 32 29 0a 28 66 73 |-int] 3]|] 2).(fs|
|00002e30| 65 74 20 27 74 73 68 65 | 6c 6c 2d 64 69 72 74 72 |et 'tshe|ll-dirtr|
|00002e40| 61 63 6b 2d 74 6f 67 67 | 6c 65 20 23 5b 6e 69 6c |ack-togg|le #[nil|
|00002e50| 20 22 08 3f 10 c1 c2 08 | ab 83 c3 aa 81 c4 5c 22 | ".?....|......\"|
|00002e60| 87 22 20 5b 74 73 68 65 | 6c 6c 2d 64 69 72 74 72 |." [tshe|ll-dirtr|
|00002e70| 61 63 6b 70 20 6d 65 73 | 73 61 67 65 20 22 44 69 |ackp mes|sage "Di|
|00002e80| 72 65 63 74 6f 72 79 20 | 74 72 61 63 6b 69 6e 67 |rectory |tracking|
|00002e90| 20 25 73 22 20 22 4f 4e | 22 20 22 4f 46 46 22 5d | %s" "ON|" "OFF"]|
|00002ea0| 20 33 20 22 5c 0a 54 75 | 72 6e 20 64 69 72 65 63 | 3 "\.Tu|rn direc|
|00002eb0| 74 6f 72 79 20 74 72 61 | 63 6b 69 6e 67 20 6f 6e |tory tra|cking on|
|00002ec0| 20 61 6e 64 20 6f 66 66 | 20 69 6e 20 61 20 73 68 | and off| in a sh|
|00002ed0| 65 6c 6c 20 62 75 66 66 | 65 72 2e 22 20 6e 69 6c |ell buff|er." nil|
|00002ee0| 5d 29 0a 28 64 65 66 61 | 6c 69 61 73 20 27 64 69 |]).(defa|lias 'di|
|00002ef0| 72 74 72 61 63 6b 2d 74 | 6f 67 67 6c 65 20 27 74 |rtrack-t|oggle 't|
|00002f00| 73 68 65 6c 6c 2d 64 69 | 72 74 72 61 63 6b 2d 74 |shell-di|rtrack-t|
|00002f10| 6f 67 67 6c 65 29 0a 28 | 66 73 65 74 20 27 74 73 |oggle).(|fset 'ts|
|00002f20| 68 65 6c 6c 2d 72 65 73 | 79 6e 63 2d 64 69 72 73 |hell-res|ync-dirs|
|00002f30| 20 23 5b 6e 69 6c 20 22 | c0 70 21 19 c2 09 21 89 | #[nil "|.p!...!.|
|00002f40| 1b 62 88 0c 63 88 c5 63 | 88 c6 c7 21 88 c8 09 0c |.b..c..c|...!....|
|00002f50| 5c 22 88 c8 09 c5 5c 22 | 88 0b 60 c9 93 88 60 1e |\"....\"|..`...`.|
|00002f60| 5c 6e c5 63 88 cb cc 21 | 88 cd ce 21 ac 8a cf 09 |\n.c...!|...!....|
|00002f70| 21 88 0e 5c 6e 62 88 aa | 71 29 0b 62 88 d0 cc 21 |!..\nb..|q).b...!|
|00002f80| 88 c7 94 c7 95 53 7b 89 | 1e 11 47 1e 12 c9 1e 13 |.....S{.|..G.....|
|00002f90| c7 1e 14 c7 0e 12 57 ab | 9e d5 d6 0e 11 0e 14 23 |......W.|.......#|
|00002fa0| 88 0e 17 0e 11 cc 94 cc | 95 4f 50 0e 13 42 16 13 |........|.OP..B..|
|00002fb0| c7 95 89 16 14 aa 5d 0e | 13 9f 1e 13 c9 d8 d9 8f |......].|........|
|00002fc0| 2e 07 87 22 20 5b 67 65 | 74 2d 62 75 66 66 65 72 |..." [ge|t-buffer|
|00002fd0| 2d 70 72 6f 63 65 73 73 | 20 70 72 6f 63 20 70 72 |-process| proc pr|
|00002fe0| 6f 63 65 73 73 2d 6d 61 | 72 6b 20 70 6d 61 72 6b |ocess-ma|rk pmark|
|00002ff0| 20 74 73 68 65 6c 6c 2d | 64 69 72 73 74 61 63 6b | tshell-|dirstack|
|00003000| 2d 71 75 65 72 79 20 22 | 5c 6e 22 20 73 69 74 2d |-query "|\n" sit-|
|00003010| 66 6f 72 20 30 20 74 65 | 72 6d 2d 73 65 6e 64 2d |for 0 te|rm-send-|
|00003020| 73 74 72 69 6e 67 20 6e | 69 6c 20 70 74 20 62 61 |string n|il pt ba|
|00003030| 63 6b 77 61 72 64 2d 63 | 68 61 72 20 31 20 6c 6f |ckward-c|har 1 lo|
|00003040| 6f 6b 69 6e 67 2d 61 74 | 20 22 2e 2b 5c 6e 22 20 |oking-at| ".+\n" |
|00003050| 61 63 63 65 70 74 2d 70 | 72 6f 63 65 73 73 2d 6f |accept-p|rocess-o|
|00003060| 75 74 70 75 74 20 64 65 | 6c 65 74 65 2d 63 68 61 |utput de|lete-cha|
|00003070| 72 20 64 6c 20 64 6c 2d | 6c 65 6e 20 64 73 20 69 |r dl dl-|len ds i|
|00003080| 20 73 74 72 69 6e 67 2d | 6d 61 74 63 68 20 22 5c | string-|match "\|
|00003090| 5c 73 20 2a 5c 5c 28 5c | 5c 53 20 2b 5c 5c 29 5c |\s *\\(\|\S +\\)\|
|000030a0| 5c 73 20 2a 22 20 74 65 | 72 6d 2d 66 69 6c 65 2d |\s *" te|rm-file-|
|000030b0| 6e 61 6d 65 2d 70 72 65 | 66 69 78 20 28 62 79 74 |name-pre|fix (byt|
|000030c0| 65 2d 63 6f 64 65 20 22 | c0 09 40 21 88 09 41 12 |e-code "|..@!..A.|
|000030d0| c3 20 87 22 20 5b 63 64 | 20 64 73 20 74 73 68 65 |. ." [cd| ds tshe|
|000030e0| 6c 6c 2d 64 69 72 73 74 | 61 63 6b 20 74 73 68 65 |ll-dirst|ack tshe|
|000030f0| 6c 6c 2d 64 69 72 73 74 | 61 63 6b 2d 6d 65 73 73 |ll-dirst|ack-mess|
|00003100| 61 67 65 5d 20 32 29 20 | 28 28 65 72 72 6f 72 20 |age] 2) |((error |
|00003110| 28 6d 65 73 73 61 67 65 | 20 22 43 6f 75 6c 64 6e |(message| "Couldn|
|00003120| 27 74 20 63 64 2e 22 29 | 29 29 5d 20 35 20 22 5c |'t cd.")|))] 5 "\|
|00003130| 0a 52 65 73 79 6e 63 20 | 74 68 65 20 62 75 66 66 |.Resync |the buff|
|00003140| 65 72 27 73 20 69 64 65 | 61 20 6f 66 20 74 68 65 |er's ide|a of the|
|00003150| 20 63 75 72 72 65 6e 74 | 20 64 69 72 65 63 74 6f | current| directo|
|00003160| 72 79 20 73 74 61 63 6b | 2e 0a 54 68 69 73 20 63 |ry stack|..This c|
|00003170| 6f 6d 6d 61 6e 64 20 71 | 75 65 72 69 65 73 20 74 |ommand q|ueries t|
|00003180| 68 65 20 73 68 65 6c 6c | 20 77 69 74 68 20 74 68 |he shell| with th|
|00003190| 65 20 63 6f 6d 6d 61 6e | 64 20 62 6f 75 6e 64 20 |e comman|d bound |
|000031a0| 74 6f 20 0a 60 74 73 68 | 65 6c 6c 2d 64 69 72 73 |to .`tsh|ell-dirs|
|000031b0| 74 61 63 6b 2d 71 75 65 | 72 79 27 20 28 64 65 66 |tack-que|ry' (def|
|000031c0| 61 75 6c 74 20 5c 22 64 | 69 72 73 5c 22 29 2c 20 |ault \"d|irs\"), |
|000031d0| 72 65 61 64 73 20 74 68 | 65 20 6e 65 78 74 0a 6c |reads th|e next.l|
|000031e0| 69 6e 65 20 6f 75 74 70 | 75 74 20 61 6e 64 20 70 |ine outp|ut and p|
|000031f0| 61 72 73 65 73 20 69 74 | 20 74 6f 20 66 6f 72 6d |arses it| to form|
|00003200| 20 74 68 65 20 6e 65 77 | 20 64 69 72 65 63 74 6f | the new| directo|
|00003210| 72 79 20 73 74 61 63 6b | 2e 0a 44 4f 4e 27 54 20 |ry stack|..DON'T |
|00003220| 69 73 73 75 65 20 74 68 | 69 73 20 63 6f 6d 6d 61 |issue th|is comma|
|00003230| 6e 64 20 75 6e 6c 65 73 | 73 20 74 68 65 20 62 75 |nd unles|s the bu|
|00003240| 66 66 65 72 20 69 73 20 | 61 74 20 61 20 73 68 65 |ffer is |at a she|
|00003250| 6c 6c 20 70 72 6f 6d 70 | 74 2e 0a 41 6c 73 6f 2c |ll promp|t..Also,|
|00003260| 20 6e 6f 74 65 20 74 68 | 61 74 20 69 66 20 73 6f | note th|at if so|
|00003270| 6d 65 20 6f 74 68 65 72 | 20 73 75 62 70 72 6f 63 |me other| subproc|
|00003280| 65 73 73 20 64 65 63 69 | 64 65 73 20 74 6f 20 64 |ess deci|des to d|
|00003290| 6f 20 6f 75 74 70 75 74 | 0a 69 6d 6d 65 64 69 61 |o output|.immedia|
|000032a0| 74 65 6c 79 20 61 66 74 | 65 72 20 74 68 65 20 71 |tely aft|er the q|
|000032b0| 75 65 72 79 2c 20 69 74 | 73 20 6f 75 74 70 75 74 |uery, it|s output|
|000032c0| 20 77 69 6c 6c 20 62 65 | 20 74 61 6b 65 6e 20 61 | will be| taken a|
|000032d0| 73 20 74 68 65 0a 6e 65 | 77 20 64 69 72 65 63 74 |s the.ne|w direct|
|000032e0| 6f 72 79 20 73 74 61 63 | 6b 20 2d 2d 20 79 6f 75 |ory stac|k -- you|
|000032f0| 20 6c 6f 73 65 2e 20 49 | 66 20 74 68 69 73 20 68 | lose. I|f this h|
|00003300| 61 70 70 65 6e 73 2c 20 | 6a 75 73 74 20 64 6f 20 |appens, |just do |
|00003310| 74 68 65 0a 63 6f 6d 6d | 61 6e 64 20 61 67 61 69 |the.comm|and agai|
|00003320| 6e 2e 22 20 6e 69 6c 5d | 29 0a 28 62 79 74 65 2d |n." nil]|).(byte-|
|00003330| 63 6f 64 65 20 22 c0 c1 | c2 5c 22 88 c3 c4 4d 87 |code "..|.\"...M.|
|00003340| 22 20 5b 64 65 66 61 6c | 69 61 73 20 64 69 72 73 |" [defal|ias dirs|
|00003350| 20 74 73 68 65 6c 6c 2d | 72 65 73 79 6e 63 2d 64 | tshell-|resync-d|
|00003360| 69 72 73 20 74 73 68 65 | 6c 6c 2d 64 69 72 73 74 |irs tshe|ll-dirst|
|00003370| 61 63 6b 2d 6d 65 73 73 | 61 67 65 20 23 5b 6e 69 |ack-mess|age #[ni|
|00003380| 6c 20 22 c0 19 5c 6e 0b | 42 1c c5 0e 06 c7 50 21 |l "..\n.|B.....P!|
|00003390| 89 1e 08 47 1e 09 0c ab | d8 0c 40 89 1e 5c 6e 47 |...G....|..@..\nG|
|000033a0| 0e 09 59 ab 95 0e 08 0e | 5c 6e cb 0e 09 4f 98 ab |..Y.....|\n...O..|
|000033b0| 8a c7 0e 5c 6e 0e 09 cc | 4f 50 16 5c 6e 0e 06 ab |...\n...|OP.\n...|
|000033c0| a6 0e 5c 6e 47 0e 06 47 | 59 ab 9d 0e 06 0e 5c 6e |..\nG..G|Y.....\n|
|000033d0| cb 0e 06 47 4f 98 ab 91 | 0e 5c 6e 0e 06 47 cc 4f |...GO...|.\n..G.O|
|000033e0| 89 16 5c 6e ab 85 0c 0e | 5c 6e a0 88 09 cd 0e 5c |..\n....|\n.....\|
|000033f0| 6e 21 ce 51 11 0c 41 14 | 29 aa 25 cf 09 21 2c 87 |n!.Q..A.|).%..!,.|
|00003400| 22 20 5b 22 22 20 6d 73 | 67 20 64 65 66 61 75 6c |" ["" ms|g defaul|
|00003410| 74 2d 64 69 72 65 63 74 | 6f 72 79 20 74 73 68 65 |t-direct|ory tshe|
|00003420| 6c 6c 2d 64 69 72 73 74 | 61 63 6b 20 64 73 20 65 |ll-dirst|ack ds e|
|00003430| 78 70 61 6e 64 2d 66 69 | 6c 65 2d 6e 61 6d 65 20 |xpand-fi|le-name |
|00003440| 74 65 72 6d 2d 66 69 6c | 65 2d 6e 61 6d 65 2d 70 |term-fil|e-name-p|
|00003450| 72 65 66 69 78 20 22 7e | 2f 22 20 68 6f 6d 65 20 |refix "~|/" home |
|00003460| 68 6f 6d 65 6c 65 6e 20 | 64 69 72 20 30 20 6e 69 |homelen |dir 0 ni|
|00003470| 6c 20 64 69 72 65 63 74 | 6f 72 79 2d 66 69 6c 65 |l direct|ory-file|
|00003480| 2d 6e 61 6d 65 20 22 20 | 22 20 6d 65 73 73 61 67 |-name " |" messag|
|00003490| 65 5d 20 35 5d 5d 20 33 | 29 0a 28 66 73 65 74 20 |e] 5]] 3|).(fset |
|000034a0| 27 74 73 68 65 6c 6c 2d | 66 6f 72 77 61 72 64 2d |'tshell-|forward-|
|000034b0| 63 6f 6d 6d 61 6e 64 20 | 23 5b 28 26 6f 70 74 69 |command |#[(&opti|
|000034c0| 6f 6e 61 6c 20 61 72 67 | 29 20 22 8a c0 7f 88 60 |onal arg|) "....`|
|000034d0| 29 19 c2 0b c4 50 09 c5 | 0e 06 24 ad 83 c7 c8 21 |)....P..|..$....!|
|000034e0| 29 87 22 20 5b 6e 69 6c | 20 6c 69 6d 69 74 20 72 |)." [nil| limit r|
|000034f0| 65 2d 73 65 61 72 63 68 | 2d 66 6f 72 77 61 72 64 |e-search|-forward|
|00003500| 20 73 68 65 6c 6c 2d 63 | 6f 6d 6d 61 6e 64 2d 72 | shell-c|ommand-r|
|00003510| 65 67 65 78 70 20 22 5c | 5c 28 5b 3b 26 7c 5d 5b |egexp "\|\([;&|][|
|00003520| 09 20 5d 2a 5c 5c 29 2b | 22 20 6d 6f 76 65 20 61 |. ]*\\)+|" move a|
|00003530| 72 67 20 73 6b 69 70 2d | 73 79 6e 74 61 78 2d 62 |rg skip-|syntax-b|
|00003540| 61 63 6b 77 61 72 64 20 | 22 20 22 5d 20 35 20 22 |ackward |" "] 5 "|
|00003550| 5c 0a 4d 6f 76 65 20 66 | 6f 72 77 61 72 64 20 61 |\.Move f|orward a|
|00003560| 63 72 6f 73 73 20 41 52 | 47 20 73 68 65 6c 6c 20 |cross AR|G shell |
|00003570| 63 6f 6d 6d 61 6e 64 28 | 73 29 2e 20 20 44 6f 65 |command(|s). Doe|
|00003580| 73 20 6e 6f 74 20 63 72 | 6f 73 73 20 6c 69 6e 65 |s not cr|oss line|
|00003590| 73 2e 0a 53 65 65 20 60 | 73 68 65 6c 6c 2d 63 6f |s..See `|shell-co|
|000035a0| 6d 6d 61 6e 64 2d 72 65 | 67 65 78 70 27 2e 22 20 |mmand-re|gexp'." |
|000035b0| 22 70 22 5d 29 0a 28 66 | 73 65 74 20 27 74 73 68 |"p"]).(f|set 'tsh|
|000035c0| 65 6c 6c 2d 62 61 63 6b | 77 61 72 64 2d 63 6f 6d |ell-back|ward-com|
|000035d0| 6d 61 6e 64 20 23 5b 28 | 26 6f 70 74 69 6f 6e 61 |mand #[(|&optiona|
|000035e0| 6c 20 61 72 67 29 20 22 | 8a c0 c1 21 88 60 29 89 |l arg) "|...!.`).|
|000035f0| 1a 60 56 ab 87 8a c3 79 | 88 60 12 29 c4 c5 5c 6e |.`V....y|.`.)..\n|
|00003600| 5c 22 88 c6 c7 c8 0e 09 | 5c 22 5c 6e ca 0e 0b 24 |\"......|\"\n...$|
|00003610| ad 87 cc 94 62 88 cd c1 | 77 29 87 22 20 5b 74 65 |....b...|w)." [te|
|00003620| 72 6d 2d 62 6f 6c 20 6e | 69 6c 20 6c 69 6d 69 74 |rm-bol n|il limit|
|00003630| 20 30 20 73 6b 69 70 2d | 73 79 6e 74 61 78 2d 62 | 0 skip-|syntax-b|
|00003640| 61 63 6b 77 61 72 64 20 | 22 20 22 20 72 65 2d 73 |ackward |" " re-s|
|00003650| 65 61 72 63 68 2d 62 61 | 63 6b 77 61 72 64 20 66 |earch-ba|ckward f|
|00003660| 6f 72 6d 61 74 20 22 5b | 3b 26 7c 5d 2b 5b 09 20 |ormat "[|;&|]+[. |
|00003670| 5d 2a 5c 5c 28 25 73 5c | 5c 29 22 20 73 68 65 6c |]*\\(%s\|\)" shel|
|00003680| 6c 2d 63 6f 6d 6d 61 6e | 64 2d 72 65 67 65 78 70 |l-comman|d-regexp|
|00003690| 20 6d 6f 76 65 20 61 72 | 67 20 31 20 22 3b 26 7c | move ar|g 1 ";&||
|000036a0| 22 5d 20 36 20 22 5c 0a | 4d 6f 76 65 20 62 61 63 |"] 6 "\.|Move bac|
|000036b0| 6b 77 61 72 64 20 61 63 | 72 6f 73 73 20 41 52 47 |kward ac|ross ARG|
|000036c0| 20 73 68 65 6c 6c 20 63 | 6f 6d 6d 61 6e 64 28 73 | shell c|ommand(s|
|000036d0| 29 2e 20 20 44 6f 65 73 | 20 6e 6f 74 20 63 72 6f |). Does| not cro|
|000036e0| 73 73 20 6c 69 6e 65 73 | 2e 0a 53 65 65 20 60 73 |ss lines|..See `s|
|000036f0| 68 65 6c 6c 2d 63 6f 6d | 6d 61 6e 64 2d 72 65 67 |hell-com|mand-reg|
|00003700| 65 78 70 27 2e 22 20 22 | 70 22 5d 29 0a 28 66 73 |exp'." "|p"]).(fs|
|00003710| 65 74 20 27 74 73 68 65 | 6c 6c 2d 64 79 6e 61 6d |et 'tshe|ll-dynam|
|00003720| 69 63 2d 63 6f 6d 70 6c | 65 74 65 2d 63 6f 6d 6d |ic-compl|ete-comm|
|00003730| 61 6e 64 20 23 5b 6e 69 | 6c 20 22 c0 20 89 19 ad |and #[ni|l ". ...|
|00003740| 9f c2 20 1b c4 8e c5 c6 | 09 5c 22 2a 3f ad 92 c7 |.. .....|.\"*?...|
|00003750| 94 8a c8 c9 21 88 60 29 | 3d ad 86 ca cb 21 88 cc |....!.`)|=....!..|
|00003760| 20 29 87 22 20 5b 74 65 | 72 6d 2d 6d 61 74 63 68 | )." [te|rm-match|
|00003770| 2d 70 61 72 74 69 61 6c | 2d 66 69 6c 65 6e 61 6d |-partial|-filenam|
|00003780| 65 20 66 69 6c 65 6e 61 | 6d 65 20 6d 61 74 63 68 |e filena|me match|
|00003790| 2d 64 61 74 61 20 5f 6d | 61 74 63 68 5f 64 61 74 |-data _m|atch_dat|
|000037a0| 61 5f 20 28 28 73 74 6f | 72 65 2d 6d 61 74 63 68 |a_ ((sto|re-match|
|000037b0| 2d 64 61 74 61 20 5f 6d | 61 74 63 68 5f 64 61 74 |-data _m|atch_dat|
|000037c0| 61 5f 29 29 20 73 74 72 | 69 6e 67 2d 6d 61 74 63 |a_)) str|ing-matc|
|000037d0| 68 20 22 5b 7e 2f 5d 22 | 20 30 20 74 73 68 65 6c |h "[~/]"| 0 tshel|
|000037e0| 6c 2d 62 61 63 6b 77 61 | 72 64 2d 63 6f 6d 6d 61 |l-backwa|rd-comma|
|000037f0| 6e 64 20 31 20 6d 65 73 | 73 61 67 65 20 22 43 6f |nd 1 mes|sage "Co|
|00003800| 6d 70 6c 65 74 69 6e 67 | 20 63 6f 6d 6d 61 6e 64 |mpleting| command|
|00003810| 20 6e 61 6d 65 2e 2e 2e | 22 20 74 73 68 65 6c 6c | name...|" tshell|
|00003820| 2d 64 79 6e 61 6d 69 63 | 2d 63 6f 6d 70 6c 65 74 |-dynamic|-complet|
|00003830| 65 2d 61 73 2d 63 6f 6d | 6d 61 6e 64 5d 20 34 20 |e-as-com|mand] 4 |
|00003840| 22 5c 0a 44 79 6e 61 6d | 69 63 61 6c 6c 79 20 63 |"\.Dynam|ically c|
|00003850| 6f 6d 70 6c 65 74 65 20 | 74 68 65 20 63 6f 6d 6d |omplete |the comm|
|00003860| 61 6e 64 20 61 74 20 70 | 6f 69 6e 74 2e 0a 54 68 |and at p|oint..Th|
|00003870| 69 73 20 66 75 6e 63 74 | 69 6f 6e 20 69 73 20 73 |is funct|ion is s|
|00003880| 69 6d 69 6c 61 72 20 74 | 6f 20 60 74 65 72 6d 2d |imilar t|o `term-|
|00003890| 64 79 6e 61 6d 69 63 2d | 63 6f 6d 70 6c 65 74 65 |dynamic-|complete|
|000038a0| 2d 66 69 6c 65 6e 61 6d | 65 27 2c 20 65 78 63 65 |-filenam|e', exce|
|000038b0| 70 74 20 74 68 61 74 20 | 69 74 0a 73 65 61 72 63 |pt that |it.searc|
|000038c0| 68 65 73 20 60 65 78 65 | 63 2d 70 61 74 68 27 20 |hes `exe|c-path' |
|000038d0| 28 6d 69 6e 75 73 20 74 | 68 65 20 74 72 61 69 6c |(minus t|he trail|
|000038e0| 69 6e 67 20 65 6d 61 63 | 73 20 6c 69 62 72 61 72 |ing emac|s librar|
|000038f0| 79 20 70 61 74 68 29 20 | 66 6f 72 20 63 6f 6d 70 |y path) |for comp|
|00003900| 6c 65 74 69 6f 6e 0a 63 | 61 6e 64 69 64 61 74 65 |letion.c|andidate|
|00003910| 73 2e 20 20 4e 6f 74 65 | 20 74 68 61 74 20 74 68 |s. Note| that th|
|00003920| 69 73 20 6d 61 79 20 6e | 6f 74 20 62 65 20 74 68 |is may n|ot be th|
|00003930| 65 20 73 61 6d 65 20 61 | 73 20 74 68 65 20 73 68 |e same a|s the sh|
|00003940| 65 6c 6c 27 73 20 69 64 | 65 61 20 6f 66 20 74 68 |ell's id|ea of th|
|00003950| 65 0a 70 61 74 68 2e 0a | 0a 43 6f 6d 70 6c 65 74 |e.path..|.Complet|
|00003960| 69 6f 6e 20 69 73 20 64 | 65 70 65 6e 64 65 6e 74 |ion is d|ependent|
|00003970| 20 6f 6e 20 74 68 65 20 | 76 61 6c 75 65 20 6f 66 | on the |value of|
|00003980| 20 60 73 68 65 6c 6c 2d | 63 6f 6d 70 6c 65 74 69 | `shell-|completi|
|00003990| 6f 6e 2d 65 78 65 63 6f | 6e 6c 79 27 2c 20 70 6c |on-execo|nly', pl|
|000039a0| 75 73 0a 74 68 6f 73 65 | 20 74 68 61 74 20 65 66 |us.those| that ef|
|000039b0| 66 65 63 74 20 66 69 6c | 65 20 63 6f 6d 70 6c 65 |fect fil|e comple|
|000039c0| 74 69 6f 6e 2e 20 20 53 | 65 65 20 60 74 73 68 65 |tion. S|ee `tshe|
|000039d0| 6c 6c 2d 64 79 6e 61 6d | 69 63 2d 63 6f 6d 70 6c |ll-dynam|ic-compl|
|000039e0| 65 74 65 2d 61 73 2d 63 | 6f 6d 6d 61 6e 64 27 2e |ete-as-c|ommand'.|
|000039f0| 0a 0a 52 65 74 75 72 6e | 73 20 74 20 69 66 20 73 |..Return|s t if s|
|00003a00| 75 63 63 65 73 73 66 75 | 6c 2e 22 20 6e 69 6c 5d |uccessfu|l." nil]|
|00003a10| 29 0a 28 66 73 65 74 20 | 27 74 73 68 65 6c 6c 2d |).(fset |'tshell-|
|00003a20| 64 79 6e 61 6d 69 63 2d | 63 6f 6d 70 6c 65 74 65 |dynamic-|complete|
|00003a30| 2d 61 73 2d 63 6f 6d 6d | 61 6e 64 20 23 5b 6e 69 |-as-comm|and #[ni|
|00003a40| 6c 20 22 c0 20 ae 81 c1 | 1a c3 5c 6e 21 1c c5 0e |l ". ...|..\n!...|
|00003a50| 06 21 41 1e 07 c8 c9 0e | 5c 6e 21 21 1e 0b 0e 0c |.!A.....|\n!!....|
|00003a60| ad 86 cd ce 0e 0c cf 23 | 1e 10 c1 1e 11 d2 1e 13 |.......#|........|
|00003a70| c1 1e 14 c1 1e 15 d2 1e | 16 0e 07 ab e9 c8 d7 0e |........|........|
|00003a80| 07 40 ae 81 d8 21 21 16 | 11 d9 0e 11 21 ad 85 da |.@...!!.|....!...|
|00003a90| 0c 0e 11 5c 22 89 16 13 | ab c5 0e 13 40 16 14 0e |...\"...|....@...|
|00003aa0| 11 0e 14 50 16 15 0e 14 | 0e 16 9d ac aa 0e 10 ab |...P....|........|
|00003ab0| 88 db 0e 10 0e 14 5c 22 | ac 9e 0e 11 0e 0b 98 ac |......\"|........|
|00003ac0| 86 dc 0e 15 21 ac 91 0e | 1d ab 86 de 0e 15 21 ab |....!...|......!.|
|00003ad0| 87 0e 14 0e 16 42 16 16 | 0e 13 41 89 16 13 ac 3b |.....B..|..A....;|
|00003ae0| 0e 07 41 89 16 07 ac 17 | d2 1e 1f e0 0c 0e 16 5c |..A.....|.......\|
|00003af0| 22 29 89 1e 21 e2 3e ab | 8d 0e 1f ab 89 dc c0 20 |")..!.>.|....... |
|00003b00| 21 ac 83 e3 63 88 0e 21 | 2e 0b 87 22 20 5b 74 65 |!...c..!|..." [te|
|00003b10| 72 6d 2d 6d 61 74 63 68 | 2d 70 61 72 74 69 61 6c |rm-match|-partial|
|00003b20| 2d 66 69 6c 65 6e 61 6d | 65 20 22 22 20 66 69 6c |-filenam|e "" fil|
|00003b30| 65 6e 61 6d 65 20 66 69 | 6c 65 2d 6e 61 6d 65 2d |ename fi|le-name-|
|00003b40| 6e 6f 6e 64 69 72 65 63 | 74 6f 72 79 20 70 61 74 |nondirec|tory pat|
|00003b50| 68 6e 6f 6e 64 69 72 20 | 72 65 76 65 72 73 65 20 |hnondir |reverse |
|00003b60| 65 78 65 63 2d 70 61 74 | 68 20 70 61 74 68 73 20 |exec-pat|h paths |
|00003b70| 66 69 6c 65 2d 6e 61 6d | 65 2d 61 73 2d 64 69 72 |file-nam|e-as-dir|
|00003b80| 65 63 74 6f 72 79 20 65 | 78 70 61 6e 64 2d 66 69 |ectory e|xpand-fi|
|00003b90| 6c 65 2d 6e 61 6d 65 20 | 64 65 66 61 75 6c 74 2d |le-name |default-|
|00003ba0| 64 69 72 65 63 74 6f 72 | 79 20 63 77 64 20 74 65 |director|y cwd te|
|00003bb0| 72 6d 2d 63 6f 6d 70 6c | 65 74 69 6f 6e 2d 66 69 |rm-compl|etion-fi|
|00003bc0| 67 6e 6f 72 65 20 6d 61 | 70 63 6f 6e 63 61 74 20 |gnore ma|pconcat |
|00003bd0| 23 5b 28 78 29 20 22 c0 | 09 21 c2 50 87 22 20 5b |#[(x) ".|.!.P." [|
|00003be0| 72 65 67 65 78 70 2d 71 | 75 6f 74 65 20 78 20 22 |regexp-q|uote x "|
|00003bf0| 24 22 5d 20 32 5d 20 22 | 5c 5c 7c 22 20 69 67 6e |$"] 2] "|\\|" ign|
|00003c00| 6f 72 65 64 2d 65 78 74 | 65 6e 73 69 6f 6e 73 20 |ored-ext|ensions |
|00003c10| 70 61 74 68 20 6e 69 6c | 20 63 6f 6d 70 73 2d 69 |path nil| comps-i|
|00003c20| 6e 2d 70 61 74 68 20 66 | 69 6c 65 20 66 69 6c 65 |n-path f|ile file|
|00003c30| 70 61 74 68 20 63 6f 6d | 70 6c 65 74 69 6f 6e 73 |path com|pletions|
|00003c40| 20 74 65 72 6d 2d 64 69 | 72 65 63 74 6f 72 79 20 | term-di|rectory |
|00003c50| 22 2e 22 20 66 69 6c 65 | 2d 61 63 63 65 73 73 69 |"." file|-accessi|
|00003c60| 62 6c 65 2d 64 69 72 65 | 63 74 6f 72 79 2d 70 20 |ble-dire|ctory-p |
|00003c70| 66 69 6c 65 2d 6e 61 6d | 65 2d 61 6c 6c 2d 63 6f |file-nam|e-all-co|
|00003c80| 6d 70 6c 65 74 69 6f 6e | 73 20 73 74 72 69 6e 67 |mpletion|s string|
|00003c90| 2d 6d 61 74 63 68 20 66 | 69 6c 65 2d 64 69 72 65 |-match f|ile-dire|
|00003ca0| 63 74 6f 72 79 2d 70 20 | 73 68 65 6c 6c 2d 63 6f |ctory-p |shell-co|
|00003cb0| 6d 70 6c 65 74 69 6f 6e | 2d 65 78 65 63 6f 6e 6c |mpletion|-execonl|
|00003cc0| 79 20 66 69 6c 65 2d 65 | 78 65 63 75 74 61 62 6c |y file-e|xecutabl|
|00003cd0| 65 2d 70 20 74 65 72 6d | 2d 63 6f 6d 70 6c 65 74 |e-p term|-complet|
|00003ce0| 69 6f 6e 2d 61 64 64 73 | 75 66 66 69 78 20 74 65 |ion-adds|uffix te|
|00003cf0| 72 6d 2d 64 79 6e 61 6d | 69 63 2d 73 69 6d 70 6c |rm-dynam|ic-simpl|
|00003d00| 65 2d 63 6f 6d 70 6c 65 | 74 65 20 73 75 63 63 65 |e-comple|te succe|
|00003d10| 73 73 20 28 73 6f 6c 65 | 20 73 68 6f 72 74 65 73 |ss (sole| shortes|
|00003d20| 74 29 20 22 20 22 5d 20 | 35 20 22 5c 0a 44 79 6e |t) " "] |5 "\.Dyn|
|00003d30| 61 6d 69 63 61 6c 6c 79 | 20 63 6f 6d 70 6c 65 74 |amically| complet|
|00003d40| 65 20 61 74 20 70 6f 69 | 6e 74 20 61 73 20 61 20 |e at poi|nt as a |
|00003d50| 63 6f 6d 6d 61 6e 64 2e | 0a 53 65 65 20 60 74 73 |command.|.See `ts|
|00003d60| 68 65 6c 6c 2d 64 79 6e | 61 6d 69 63 2d 63 6f 6d |hell-dyn|amic-com|
|00003d70| 70 6c 65 74 65 2d 66 69 | 6c 65 6e 61 6d 65 27 2e |plete-fi|lename'.|
|00003d80| 20 20 52 65 74 75 72 6e | 73 20 74 20 69 66 20 73 | Return|s t if s|
|00003d90| 75 63 63 65 73 73 66 75 | 6c 2e 22 5d 29 0a 28 66 |uccessfu|l."]).(f|
|00003da0| 73 65 74 20 27 74 73 68 | 65 6c 6c 2d 6d 61 74 63 |set 'tsh|ell-matc|
|00003db0| 68 2d 70 61 72 74 69 61 | 6c 2d 76 61 72 69 61 62 |h-partia|l-variab|
|00003dc0| 6c 65 20 23 5b 6e 69 6c | 20 22 8a 60 18 c1 c2 c3 |le #[nil| ".`....|
|00003dd0| c4 23 ab 88 c5 c6 21 ac | 83 c7 75 88 6c ae 83 c5 |.#....!.|..u.l...|
|00003de0| c8 21 3f ad 8a c9 ca 08 | 5c 22 88 cb 94 cb 95 7b |.!?.....|\".....{|
|00003df0| 2a 87 22 20 5b 6c 69 6d | 69 74 20 72 65 2d 73 65 |*." [lim|it re-se|
|00003e00| 61 72 63 68 2d 62 61 63 | 6b 77 61 72 64 20 22 5b |arch-bac|kward "[|
|00003e10| 5e 41 2d 5a 61 2d 7a 30 | 2d 39 5f 7b 7d 5d 22 20 |^A-Za-z0|-9_{}]" |
|00003e20| 6e 69 6c 20 6d 6f 76 65 | 20 6c 6f 6f 6b 69 6e 67 |nil move| looking|
|00003e30| 2d 61 74 20 22 5c 5c 24 | 22 20 31 20 22 5b 5e 41 |-at "\\$|" 1 "[^A|
|00003e40| 2d 5a 61 2d 7a 30 2d 39 | 5f 7b 7d 24 5d 22 20 72 |-Za-z0-9|_{}$]" r|
|00003e50| 65 2d 73 65 61 72 63 68 | 2d 66 6f 72 77 61 72 64 |e-search|-forward|
|00003e60| 20 22 5c 5c 24 3f 7b 3f | 5b 41 2d 5a 61 2d 7a 30 | "\\$?{?|[A-Za-z0|
|00003e70| 2d 39 5f 5d 2a 7d 3f 22 | 20 30 5d 20 34 20 22 5c |-9_]*}?"| 0] 4 "\|
|00003e80| 0a 52 65 74 75 72 6e 20 | 74 68 65 20 76 61 72 69 |.Return |the vari|
|00003e90| 61 62 6c 65 20 61 74 20 | 70 6f 69 6e 74 2c 20 6f |able at |point, o|
|00003ea0| 72 20 6e 69 6c 20 69 66 | 20 6e 6f 6e 20 69 73 20 |r nil if| non is |
|00003eb0| 66 6f 75 6e 64 2e 22 5d | 29 0a 28 66 73 65 74 20 |found."]|).(fset |
|00003ec0| 27 74 73 68 65 6c 6c 2d | 64 79 6e 61 6d 69 63 2d |'tshell-|dynamic-|
|00003ed0| 63 6f 6d 70 6c 65 74 65 | 2d 65 6e 76 69 72 6f 6e |complete|-environ|
|00003ee0| 6d 65 6e 74 2d 76 61 72 | 69 61 62 6c 65 20 23 5b |ment-var|iable #[|
|00003ef0| 6e 69 6c 20 22 c0 20 89 | 19 ad 8c c2 c3 09 5c 22 |nil ". .|......\"|
|00003f00| ad 86 c4 c5 21 88 c6 20 | 29 87 22 20 5b 74 73 68 |....!.. |)." [tsh|
|00003f10| 65 6c 6c 2d 6d 61 74 63 | 68 2d 70 61 72 74 69 61 |ell-matc|h-partia|
|00003f20| 6c 2d 76 61 72 69 61 62 | 6c 65 20 76 61 72 69 61 |l-variab|le varia|
|00003f30| 62 6c 65 20 73 74 72 69 | 6e 67 2d 6d 61 74 63 68 |ble stri|ng-match|
|00003f40| 20 22 5e 5c 5c 24 22 20 | 6d 65 73 73 61 67 65 20 | "^\\$" |message |
|00003f50| 22 43 6f 6d 70 6c 65 74 | 69 6e 67 20 76 61 72 69 |"Complet|ing vari|
|00003f60| 61 62 6c 65 20 6e 61 6d | 65 2e 2e 2e 22 20 74 73 |able nam|e..." ts|
|00003f70| 68 65 6c 6c 2d 64 79 6e | 61 6d 69 63 2d 63 6f 6d |hell-dyn|amic-com|
|00003f80| 70 6c 65 74 65 2d 61 73 | 2d 65 6e 76 69 72 6f 6e |plete-as|-environ|
|00003f90| 6d 65 6e 74 2d 76 61 72 | 69 61 62 6c 65 5d 20 34 |ment-var|iable] 4|
|00003fa0| 20 22 5c 0a 44 79 6e 61 | 6d 69 63 61 6c 6c 79 20 | "\.Dyna|mically |
|00003fb0| 63 6f 6d 70 6c 65 74 65 | 20 74 68 65 20 65 6e 76 |complete| the env|
|00003fc0| 69 72 6f 6e 6d 65 6e 74 | 20 76 61 72 69 61 62 6c |ironment| variabl|
|00003fd0| 65 20 61 74 20 70 6f 69 | 6e 74 2e 0a 43 6f 6d 70 |e at poi|nt..Comp|
|00003fe0| 6c 65 74 65 73 20 69 66 | 20 61 66 74 65 72 20 61 |letes if| after a|
|00003ff0| 20 76 61 72 69 61 62 6c | 65 2c 20 69 2e 65 2e 2c | variabl|e, i.e.,|
|00004000| 20 69 66 20 69 74 20 73 | 74 61 72 74 73 20 77 69 | if it s|tarts wi|
|00004010| 74 68 20 61 20 5c 22 24 | 5c 22 2e 0a 53 65 65 20 |th a \"$|\"..See |
|00004020| 60 74 73 68 65 6c 6c 2d | 64 79 6e 61 6d 69 63 2d |`tshell-|dynamic-|
|00004030| 63 6f 6d 70 6c 65 74 65 | 2d 61 73 2d 65 6e 76 69 |complete|-as-envi|
|00004040| 72 6f 6e 6d 65 6e 74 2d | 76 61 72 69 61 62 6c 65 |ronment-|variable|
|00004050| 27 2e 0a 0a 54 68 69 73 | 20 66 75 6e 63 74 69 6f |'...This| functio|
|00004060| 6e 20 69 73 20 73 69 6d | 69 6c 61 72 20 74 6f 20 |n is sim|ilar to |
|00004070| 60 74 65 72 6d 2d 64 79 | 6e 61 6d 69 63 2d 63 6f |`term-dy|namic-co|
|00004080| 6d 70 6c 65 74 65 2d 66 | 69 6c 65 6e 61 6d 65 27 |mplete-f|ilename'|
|00004090| 2c 20 65 78 63 65 70 74 | 20 74 68 61 74 20 69 74 |, except| that it|
|000040a0| 0a 73 65 61 72 63 68 65 | 73 20 60 70 72 6f 63 65 |.searche|s `proce|
|000040b0| 73 73 2d 65 6e 76 69 72 | 6f 6e 6d 65 6e 74 27 20 |ss-envir|onment' |
|000040c0| 66 6f 72 20 63 6f 6d 70 | 6c 65 74 69 6f 6e 20 63 |for comp|letion c|
|000040d0| 61 6e 64 69 64 61 74 65 | 73 2e 20 20 4e 6f 74 65 |andidate|s. Note|
|000040e0| 20 74 68 61 74 20 74 68 | 69 73 20 6d 61 79 0a 6e | that th|is may.n|
|000040f0| 6f 74 20 62 65 20 74 68 | 65 20 73 61 6d 65 20 61 |ot be th|e same a|
|00004100| 73 20 74 68 65 20 69 6e | 74 65 72 70 72 65 74 65 |s the in|terprete|
|00004110| 72 27 73 20 69 64 65 61 | 20 6f 66 20 76 61 72 69 |r's idea| of vari|
|00004120| 61 62 6c 65 20 6e 61 6d | 65 73 2e 20 20 54 68 65 |able nam|es. The|
|00004130| 20 6d 61 69 6e 20 70 72 | 6f 62 6c 65 6d 0a 77 69 | main pr|oblem.wi|
|00004140| 74 68 20 74 68 69 73 20 | 74 79 70 65 20 6f 66 20 |th this |type of |
|00004150| 63 6f 6d 70 6c 65 74 69 | 6f 6e 20 69 73 20 74 68 |completi|on is th|
|00004160| 61 74 20 60 70 72 6f 63 | 65 73 73 2d 65 6e 76 69 |at `proc|ess-envi|
|00004170| 72 6f 6e 6d 65 6e 74 27 | 20 69 73 20 74 68 65 20 |ronment'| is the |
|00004180| 65 6e 76 69 72 6f 6e 6d | 65 6e 74 0a 77 68 69 63 |environm|ent.whic|
|00004190| 68 20 45 6d 61 63 73 20 | 73 74 61 72 74 65 64 20 |h Emacs |started |
|000041a0| 77 69 74 68 2e 20 20 45 | 6d 61 63 73 20 64 6f 65 |with. E|macs doe|
|000041b0| 73 20 6e 6f 74 20 74 72 | 61 63 6b 20 63 68 61 6e |s not tr|ack chan|
|000041c0| 67 65 73 20 74 6f 20 74 | 68 65 20 65 6e 76 69 72 |ges to t|he envir|
|000041d0| 6f 6e 6d 65 6e 74 20 6d | 61 64 65 0a 62 79 20 74 |onment m|ade.by t|
|000041e0| 68 65 20 69 6e 74 65 72 | 70 72 65 74 65 72 2e 20 |he inter|preter. |
|000041f0| 20 50 65 72 68 61 70 73 | 20 69 74 20 77 6f 75 6c | Perhaps| it woul|
|00004200| 64 20 62 65 20 6d 6f 72 | 65 20 61 63 63 75 72 61 |d be mor|e accura|
|00004210| 74 65 20 69 66 20 74 68 | 69 73 20 66 75 6e 63 74 |te if th|is funct|
|00004220| 69 6f 6e 20 77 61 73 0a | 63 61 6c 6c 65 64 20 60 |ion was.|called `|
|00004230| 74 73 68 65 6c 6c 2d 64 | 79 6e 61 6d 69 63 2d 63 |tshell-d|ynamic-c|
|00004240| 6f 6d 70 6c 65 74 65 2d | 70 72 6f 63 65 73 73 2d |omplete-|process-|
|00004250| 65 6e 76 69 72 6f 6e 6d | 65 6e 74 2d 76 61 72 69 |environm|ent-vari|
|00004260| 61 62 6c 65 27 2e 0a 0a | 52 65 74 75 72 6e 73 20 |able'...|Returns |
|00004270| 6e 6f 6e 2d 6e 69 6c 20 | 69 66 20 73 75 63 63 65 |non-nil |if succe|
|00004280| 73 73 66 75 6c 2e 22 20 | 6e 69 6c 5d 29 0a 28 66 |ssful." |nil]).(f|
|00004290| 73 65 74 20 27 74 73 68 | 65 6c 6c 2d 64 79 6e 61 |set 'tsh|ell-dyna|
|000042a0| 6d 69 63 2d 63 6f 6d 70 | 6c 65 74 65 2d 61 73 2d |mic-comp|lete-as-|
|000042b0| 65 6e 76 69 72 6f 6e 6d | 65 6e 74 2d 76 61 72 69 |environm|ent-vari|
|000042c0| 61 62 6c 65 20 23 5b 6e | 69 6c 20 22 c0 20 ae 81 |able #[n|il ". ..|
|000042d0| c1 89 1a c3 c4 5c 6e 5c | 22 ae 81 c5 c6 4f 1e 07 |.....\n\|"....O..|
|000042e0| c8 c9 0e 5c 6e 5c 22 1e | 0b 0e 0c 1e 0d c6 1e 0c |...\n\".|........|
|000042f0| ce 0e 07 0e 0b 5c 22 89 | 1e 0f d0 3e ab c0 c0 20 |.....\".|...>... |
|00004300| 89 1a c3 d1 5c 6e 5c 22 | c6 4f 1e 07 c3 d2 5c 6e |....\n\"|.O....\n|
|00004310| 5c 22 ab 83 d3 aa 8a c3 | d4 5c 6e 5c 22 ab 83 d5 |\"......|.\n\"...|
|00004320| aa 81 c1 1e 16 0e 0d ac | 83 c1 aa 8e d7 d8 d9 0e |........|........|
|00004330| 07 21 21 21 ab 83 da aa | 81 db 1e 1c 0e 16 0e 1c |.!!!....|........|
|00004340| b1 02 88 2c 0e 0f 2e 06 | 87 22 20 5b 74 73 68 65 |...,....|." [tshe|
|00004350| 6c 6c 2d 6d 61 74 63 68 | 2d 70 61 72 74 69 61 6c |ll-match|-partial|
|00004360| 2d 76 61 72 69 61 62 6c | 65 20 22 22 20 76 61 72 |-variabl|e "" var|
|00004370| 20 73 74 72 69 6e 67 2d | 6d 61 74 63 68 20 22 5b | string-|match "[|
|00004380| 5e 24 28 7b 5d 5c 5c 7c | 24 22 20 30 20 6e 69 6c |^$({]\\||$" 0 nil|
|00004390| 20 76 61 72 69 61 62 6c | 65 20 6d 61 70 63 61 72 | variabl|e mapcar|
|000043a0| 20 23 5b 28 78 29 20 22 | 08 c1 c2 c3 08 5c 22 4f | #[(x) "|.....\"O|
|000043b0| 87 22 20 5b 78 20 30 20 | 73 74 72 69 6e 67 2d 6d |." [x 0 |string-m|
|000043c0| 61 74 63 68 20 22 3d 22 | 5d 20 35 5d 20 70 72 6f |atch "="|] 5] pro|
|000043d0| 63 65 73 73 2d 65 6e 76 | 69 72 6f 6e 6d 65 6e 74 |cess-env|ironment|
|000043e0| 20 76 61 72 69 61 62 6c | 65 73 20 74 65 72 6d 2d | variabl|es term-|
|000043f0| 63 6f 6d 70 6c 65 74 69 | 6f 6e 2d 61 64 64 73 75 |completi|on-addsu|
|00004400| 66 66 69 78 20 61 64 64 | 73 75 66 66 69 78 20 74 |ffix add|suffix t|
|00004410| 65 72 6d 2d 64 79 6e 61 | 6d 69 63 2d 73 69 6d 70 |erm-dyna|mic-simp|
|00004420| 6c 65 2d 63 6f 6d 70 6c | 65 74 65 20 73 75 63 63 |le-compl|ete succ|
|00004430| 65 73 73 20 28 73 6f 6c | 65 20 73 68 6f 72 74 65 |ess (sol|e shorte|
|00004440| 73 74 29 20 22 5b 5e 24 | 28 7b 5d 22 20 22 7b 22 |st) "[^$|({]" "{"|
|00004450| 20 22 7d 22 20 22 28 22 | 20 22 29 22 20 70 72 6f | "}" "("| ")" pro|
|00004460| 74 65 63 74 69 6f 6e 20 | 66 69 6c 65 2d 64 69 72 |tection |file-dir|
|00004470| 65 63 74 6f 72 79 2d 70 | 20 74 65 72 6d 2d 64 69 |ectory-p| term-di|
|00004480| 72 65 63 74 6f 72 79 20 | 67 65 74 65 6e 76 20 22 |rectory |getenv "|
|00004490| 2f 22 20 22 20 22 20 73 | 75 66 66 69 78 5d 20 35 |/" " " s|uffix] 5|
|000044a0| 20 22 5c 0a 44 79 6e 61 | 6d 69 63 61 6c 6c 79 20 | "\.Dyna|mically |
|000044b0| 63 6f 6d 70 6c 65 74 65 | 20 61 74 20 70 6f 69 6e |complete| at poin|
|000044c0| 74 20 61 73 20 61 6e 20 | 65 6e 76 69 72 6f 6e 6d |t as an |environm|
|000044d0| 65 6e 74 20 76 61 72 69 | 61 62 6c 65 2e 0a 55 73 |ent vari|able..Us|
|000044e0| 65 64 20 62 79 20 60 74 | 73 68 65 6c 6c 2d 64 79 |ed by `t|shell-dy|
|000044f0| 6e 61 6d 69 63 2d 63 6f | 6d 70 6c 65 74 65 2d 65 |namic-co|mplete-e|
|00004500| 6e 76 69 72 6f 6e 6d 65 | 6e 74 2d 76 61 72 69 61 |nvironme|nt-varia|
|00004510| 62 6c 65 27 2e 0a 55 73 | 65 73 20 60 74 65 72 6d |ble'..Us|es `term|
|00004520| 2d 64 79 6e 61 6d 69 63 | 2d 73 69 6d 70 6c 65 2d |-dynamic|-simple-|
|00004530| 63 6f 6d 70 6c 65 74 65 | 27 2e 22 5d 29 0a 28 66 |complete|'."]).(f|
|00004540| 73 65 74 20 27 74 73 68 | 65 6c 6c 2d 72 65 70 6c |set 'tsh|ell-repl|
|00004550| 61 63 65 2d 62 79 2d 65 | 78 70 61 6e 64 65 64 2d |ace-by-e|xpanded-|
|00004560| 64 69 72 65 63 74 6f 72 | 79 20 23 5b 6e 69 6c 20 |director|y #[nil |
|00004570| 22 c0 20 ad c9 8a c1 94 | 62 88 5c 6e 0b 42 c4 c5 |". .....|b.\n.B..|
|00004580| 21 ab 84 0b 47 aa 8c c4 | c6 21 ad 87 c7 c8 94 c8 |!...G...|.!......|
|00004590| 95 7b 21 1e 09 1e 5c 6e | 0e 09 ac 83 cb aa a0 0e |.{!...\n|........|
|000045a0| 09 0e 5c 6e 47 59 ab 85 | cc cd 21 aa 93 ce cf 0e |..\nGY..|..!.....|
|000045b0| 09 0e 5c 6e 38 21 d0 89 | 23 88 d1 d2 0e 09 5c 22 |..\n8!..|#.....\"|
|000045c0| 88 d0 2b 87 22 20 5b 74 | 65 72 6d 2d 6d 61 74 63 |..+." [t|erm-matc|
|000045d0| 68 2d 70 61 72 74 69 61 | 6c 2d 66 69 6c 65 6e 61 |h-partia|l-filena|
|000045e0| 6d 65 20 30 20 64 65 66 | 61 75 6c 74 2d 64 69 72 |me 0 def|ault-dir|
|000045f0| 65 63 74 6f 72 79 20 74 | 73 68 65 6c 6c 2d 64 69 |ectory t|shell-di|
|00004600| 72 73 74 61 63 6b 20 6c | 6f 6f 6b 69 6e 67 2d 61 |rstack l|ooking-a|
|00004610| 74 20 22 3d 2d 2f 3f 22 | 20 22 3d 5c 5c 28 5b 30 |t "=-/?"| "=\\([0|
|00004620| 2d 39 5d 2b 5c 5c 29 22 | 20 73 74 72 69 6e 67 2d |-9]+\\)"| string-|
|00004630| 74 6f 2d 6e 75 6d 62 65 | 72 20 31 20 69 6e 64 65 |to-numbe|r 1 inde|
|00004640| 78 20 73 74 61 63 6b 20 | 6e 69 6c 20 65 72 72 6f |x stack |nil erro|
|00004650| 72 20 22 44 69 72 65 63 | 74 6f 72 79 20 73 74 61 |r "Direc|tory sta|
|00004660| 63 6b 20 6e 6f 74 20 74 | 68 61 74 20 64 65 65 70 |ck not t|hat deep|
|00004670| 2e 22 20 72 65 70 6c 61 | 63 65 2d 6d 61 74 63 68 |." repla|ce-match|
|00004680| 20 66 69 6c 65 2d 6e 61 | 6d 65 2d 61 73 2d 64 69 | file-na|me-as-di|
|00004690| 72 65 63 74 6f 72 79 20 | 74 20 6d 65 73 73 61 67 |rectory |t messag|
|000046a0| 65 20 22 44 69 72 65 63 | 74 6f 72 79 20 69 74 65 |e "Direc|tory ite|
|000046b0| 6d 3a 20 25 64 22 5d 20 | 34 20 22 5c 0a 45 78 70 |m: %d"] |4 "\.Exp|
|000046c0| 61 6e 64 20 64 69 72 65 | 63 74 6f 72 79 20 73 74 |and dire|ctory st|
|000046d0| 61 63 6b 20 72 65 66 65 | 72 65 6e 63 65 20 62 65 |ack refe|rence be|
|000046e0| 66 6f 72 65 20 70 6f 69 | 6e 74 2e 0a 44 69 72 65 |fore poi|nt..Dire|
|000046f0| 63 74 6f 72 79 20 73 74 | 61 63 6b 20 72 65 66 65 |ctory st|ack refe|
|00004700| 72 65 6e 63 65 73 20 61 | 72 65 20 6f 66 20 74 68 |rences a|re of th|
|00004710| 65 20 66 6f 72 6d 20 5c | 22 3d 64 69 67 69 74 5c |e form \|"=digit\|
|00004720| 22 20 6f 72 20 5c 22 3d | 2d 5c 22 2e 0a 53 65 65 |" or \"=|-\"..See|
|00004730| 20 60 64 65 66 61 75 6c | 74 2d 64 69 72 65 63 74 | `defaul|t-direct|
|00004740| 6f 72 79 27 20 61 6e 64 | 20 60 74 73 68 65 6c 6c |ory' and| `tshell|
|00004750| 2d 64 69 72 73 74 61 63 | 6b 27 2e 0a 0a 52 65 74 |-dirstac|k'...Ret|
|00004760| 75 72 6e 73 20 74 20 69 | 66 20 73 75 63 63 65 73 |urns t i|f succes|
|00004770| 73 66 75 6c 2e 22 20 6e | 69 6c 5d 29 0a 28 70 72 |sful." n|il]).(pr|
|00004780| 6f 76 69 64 65 20 27 74 | 73 68 65 6c 6c 29 0a |ovide 't|shell). |
+--------+-------------------------+-------------------------+--------+--------+